Class with Vulkan helper functions. This class provides static functions that can be called directly without creating an object.
More...
|
static VkCommandBuffer | cmdBegin (ptr< Device > pDevice) |
| Create a new one-time use command buffer. This call should be paired with a corresponding call to cmdEnd().
|
|
static void | cmdEnd (ptr< Device > pDevice, VkCommandBuffer cmd, const std::vector< VkSemaphore > &waitSemaphores={}, const std::vector< VkPipelineStageFlags > &waitStages={}, const std::vector< VkSemaphore > &signalSemaphores={}) |
| End a one-time use command buffer that was initialized with a call to cmdBegin().
|
|
static uint32_t | findMemoryType (ptr< Device > pDevice, uint32_t typeFilter, VkMemoryPropertyFlags properties) |
| Find a suitable memory type given the memory properties.
|
|
static VkFormat | findSupportedFormat (ptr< Device > pDevice, std::vector< VkFormat > candidates, VkImageTiling tiling, VkFormatFeatureFlags features) |
| Find supported format for an attachment.
|
|
static VkFormat | findDepthFormat (ptr< Device > pDevice) |
| Find a supported depth format for a depth attachment.
|
|
static void | imageBarrier (VkCommandBuffer cmd, VkImage image, VkPipelineStageFlags2 srcStage, VkAccessFlags2 srcAccess, VkPipelineStageFlags2 dstStage, VkAccessFlags2 dstAccess, VkImageLayout oldLayout, VkImageLayout newLayout, VkImageSubresourceRange *pSubresourceRange=nullptr) |
| Create an image barrier with layout transition.
|
|
static void | copyBufferToImage (VkCommandBuffer cmd, VkBuffer buffer, VkImage image, uint32_t width, uint32_t height, uint32_t depth) |
| Copy a buffer to an image.
|
|
static void | copyImageToBuffer (VkCommandBuffer cmd, VkImage image, VkBuffer buffer, uint32_t width, uint32_t height, uint32_t depth) |
| Copy an image to a buffer.
|
|
static VkDeviceSize | alignTo (VkDeviceSize value, VkDeviceSize alignment) |
| Aligne a value to a given alignment.
|
|
static float | random (bool reset=false) |
| Return a random value from the interval [0.0, 1.0)
|
|
Class with Vulkan helper functions. This class provides static functions that can be called directly without creating an object.