![]() |
HoviTron Video Pipeline
|
class that manages tasks related to Vulkan context (Vulkan Instance, Vulkan Physical device, Vulkan Logical device) More...
#include <VulkanContext.h>
Public Member Functions | |
VulkanContext (WindowAbstract *window) | |
void | initVulkan () |
void | cleanUp () |
bool | isInitialized () |
QueueFamilyIndices | findQueueFamilies (vk::PhysicalDevice device) |
vk::Format | findSupportedFormat (const std::vector< vk::Format > &candidates, vk::ImageTiling tiling, vk::FormatFeatureFlags features) |
vk::Format | findDepthFormat () |
bool | hasStencilComponent (vk::Format format) |
bool | isIndepFromWindowDimension () |
WindowAbstract * | get_window () |
Data Fields | |
vk::Instance | instance |
vk::PhysicalDevice | physicalDevice |
vk::Device | device |
vk::Queue | graphicsQueue |
vk::Queue | presentQueue |
vk::Queue | transferQueue |
uint32_t | queueFamilyIndex =0 |
uint32_t | transferQueueFamilyIndex = 0 |
class that manages tasks related to Vulkan context (Vulkan Instance, Vulkan Physical device, Vulkan Logical device)
Manage Vulkan Instance, Vulkan Physical device, Vulkan Logical device, queues families This class also has the task to pick the correct gpu exept if openxr already chose it.
Definition at line 59 of file VulkanContext.h.
VulkanContext::VulkanContext | ( | WindowAbstract * | window | ) |
void VulkanContext::cleanUp | ( | ) |
Clean up Vulkan objects
Definition at line 622 of file VulkanContext.cpp.
vk::Format VulkanContext::findDepthFormat | ( | ) |
find the depth format
Definition at line 541 of file VulkanContext.cpp.
QueueFamilyIndices VulkanContext::findQueueFamilies | ( | vk::PhysicalDevice | device | ) |
return the queue family for presentation and graphics
Definition at line 493 of file VulkanContext.cpp.
vk::Format VulkanContext::findSupportedFormat | ( | const std::vector< vk::Format > & | candidates, |
vk::ImageTiling | tiling, | ||
vk::FormatFeatureFlags | features | ||
) |
find the supported depth format
Definition at line 527 of file VulkanContext.cpp.
|
inline |
Return a pointer to WindowAbstract class
Definition at line 108 of file VulkanContext.h.
bool VulkanContext::hasStencilComponent | ( | vk::Format | format | ) |
return true if the format have a stencil component
Definition at line 284 of file VulkanContext.cpp.
void VulkanContext::initVulkan | ( | ) |
Initialize the Vulkan instance, pick the physical device, logical device
Definition at line 152 of file VulkanContext.cpp.
bool VulkanContext::isIndepFromWindowDimension | ( | ) |
return true if rendering must be independent of screen dimension
Definition at line 289 of file VulkanContext.cpp.
bool VulkanContext::isInitialized | ( | ) |
return true if initialized
Definition at line 642 of file VulkanContext.cpp.
vk::Device VulkanContext::device |
Vulkan device
Definition at line 87 of file VulkanContext.h.
vk::Queue VulkanContext::graphicsQueue |
Queue selected for graphics operation
Definition at line 89 of file VulkanContext.h.
vk::Instance VulkanContext::instance |
Vulkan Instance
Definition at line 83 of file VulkanContext.h.
vk::PhysicalDevice VulkanContext::physicalDevice |
Vulkan PhysicalDevice (aka the GPU selected)
Definition at line 85 of file VulkanContext.h.
vk::Queue VulkanContext::presentQueue |
Queue select�ed for presentation operation, can be the same as graphicsQueue
Definition at line 91 of file VulkanContext.h.
uint32_t VulkanContext::queueFamilyIndex =0 |
Queue Family Index
Definition at line 95 of file VulkanContext.h.
vk::Queue VulkanContext::transferQueue |
Queue select�ed for transfer operation
Definition at line 93 of file VulkanContext.h.
uint32_t VulkanContext::transferQueueFamilyIndex = 0 |
Transfer family index
Definition at line 98 of file VulkanContext.h.