VenomEngine
Cross-Platform Modern Graphics Engine
Loading...
Searching...
No Matches
venom::vulkan::DescriptorPool Class Reference

Public Member Functions

DescriptorPooloperator= (const DescriptorPool &other)=delete
 
 DescriptorPool (const DescriptorPool &other)=delete
 
DescriptorPooloperator= (DescriptorPool &&other) noexcept=delete
 
 DescriptorPool (DescriptorPool &&other) noexcept=delete
 
void AddPoolSize (VkDescriptorType type, uint32_t count)
 
void AddDescriptorSetLayoutBinding (const uint32_t descriptorSetIndex, const uint32_t binding, const VkDescriptorType type, const uint32_t descriptorCount, const VkShaderStageFlags stageFlags)
 Add a descriptor set layout binding to the pipeline For HLSL shader writing, refer to https://github.com/microsoft/DirectXShaderCompiler/blob/080aeb7199e66e4b0a2b6383fd26a9f8d2cccbf5/docs/SPIR-V.rst#:~:text=Without%20attribute%20and%20command%2Dline%20option%2C,so%20this%20may%20cause%20overlap.
 
void SetDescriptorSetLayoutCreateFlags (const uint32_t descriptorSetIndex, const VkDescriptorSetLayoutCreateFlags flags)
 Set the descriptor set layout create flags.
 
void SetDescriptorSetLayoutBindingSpecifications (const uint32_t descriptorSetIndex, const VkDescriptorBindingFlags flags)
 Set the descriptor set layout binding specifications.
 
void SetDescriptorSetLayoutMaxSets (const uint32_t descriptorSetIndex, const uint32_t flags)
 Set the descriptor set layout max sets.
 
void SetDescriptorSetLayoutBindless (const uint32_t descriptorSetIndex)
 
vc::Error Create (VkDescriptorPoolCreateFlags flags, uint32_t maxSets=VENOM_MAX_FRAMES_IN_FLIGHT)
 
std::vector< DescriptorSetGroupAllocateSets (const VkDescriptorSetLayout &layout, uint32_t count, const bool bindless) const
 
std::vector< DescriptorSetGroupAllocateSets (const std::vector< VkDescriptorSetLayout > &layouts, const bool bindless) const
 
std::vector< DescriptorSetGroupAllocator > & GetDescriptorSets ()
 
std::vector< DescriptorSetLayout > & GetDescriptorSetLayouts ()
 
std::vector< VkDescriptorSetLayout > & GetVkDescriptorSetLayouts ()
 
DescriptorSetGroupAllocatorGetDescriptorSets (const uint32_t index)
 Gets the descriptor sets from the specified set index returns a vector of size VENOM_MAX_FRAMES_IN_FLIGHT because of the multiple swapchain images to handle.
 
void BindDescriptorSets (const int descriptorSetIndex, const CommandBuffer &commandBuffer, const VulkanShaderPipeline &pipeline, const VkPipelineBindPoint bindPoint)
 Bind all descriptor sets to the pipeline for the current image.
 
void BindDescriptorSets (const int descriptorSetIndex, const CommandBuffer &commandBuffer, const VulkanShaderPipeline &pipeline, const VkPipelineBindPoint bindPoint, const std::vector< uint32_t > &dynamicOffsets)
 Bind all descriptor sets to the pipeline for the current image.
 
VkDescriptorPool GetVkDescriptorPool () const
 

Static Public Member Functions

static DescriptorPoolGetPool ()
 

Member Function Documentation

◆ AddDescriptorSetLayoutBinding()

void venom::vulkan::DescriptorPool::AddDescriptorSetLayoutBinding ( const uint32_t descriptorSetIndex,
const uint32_t binding,
const VkDescriptorType type,
const uint32_t descriptorCount,
const VkShaderStageFlags stageFlags )

Add a descriptor set layout binding to the pipeline For HLSL shader writing, refer to https://github.com/microsoft/DirectXShaderCompiler/blob/080aeb7199e66e4b0a2b6383fd26a9f8d2cccbf5/docs/SPIR-V.rst#:~:text=Without%20attribute%20and%20command%2Dline%20option%2C,so%20this%20may%20cause%20overlap.

Parameters
descriptorSetIndex
binding
type
descriptorCount
stageFlags

◆ BindDescriptorSets() [1/2]

void venom::vulkan::DescriptorPool::BindDescriptorSets ( const int descriptorSetIndex,
const CommandBuffer & commandBuffer,
const VulkanShaderPipeline & pipeline,
const VkPipelineBindPoint bindPoint )

Bind all descriptor sets to the pipeline for the current image.

Parameters
descriptorSetIndex
commandBuffer
shaderPipelineShader Pipeline we are binding the descriptor sets to
bindPoint

◆ BindDescriptorSets() [2/2]

void venom::vulkan::DescriptorPool::BindDescriptorSets ( const int descriptorSetIndex,
const CommandBuffer & commandBuffer,
const VulkanShaderPipeline & pipeline,
const VkPipelineBindPoint bindPoint,
const std::vector< uint32_t > & dynamicOffsets )

Bind all descriptor sets to the pipeline for the current image.

Parameters
descriptorSetIndex
commandBuffer
shaderPipelineShader Pipeline we are binding the descriptor sets to
bindPoint
dynamicOffsets

◆ GetDescriptorSets()

DescriptorSetGroupAllocator & venom::vulkan::DescriptorPool::GetDescriptorSets ( const uint32_t index)
inline

Gets the descriptor sets from the specified set index returns a vector of size VENOM_MAX_FRAMES_IN_FLIGHT because of the multiple swapchain images to handle.

Returns
std::vector<DescriptorSet> &

◆ SetDescriptorSetLayoutBindingSpecifications()

void venom::vulkan::DescriptorPool::SetDescriptorSetLayoutBindingSpecifications ( const uint32_t descriptorSetIndex,
const VkDescriptorBindingFlags flags )

Set the descriptor set layout binding specifications.

Parameters
descriptorSetIndex
flagsBinding Flags

◆ SetDescriptorSetLayoutCreateFlags()

void venom::vulkan::DescriptorPool::SetDescriptorSetLayoutCreateFlags ( const uint32_t descriptorSetIndex,
const VkDescriptorSetLayoutCreateFlags flags )

Set the descriptor set layout create flags.

Parameters
descriptorSetIndex
flags

◆ SetDescriptorSetLayoutMaxSets()

void venom::vulkan::DescriptorPool::SetDescriptorSetLayoutMaxSets ( const uint32_t descriptorSetIndex,
const uint32_t flags )

Set the descriptor set layout max sets.

Parameters
descriptorSetIndex
maxSets

The documentation for this class was generated from the following files: