Class VulkanDescriptorPool#

Inheritance Relationships#

Base Type#

Class Documentation#

class VulkanDescriptorPool : public TRAP::Graphics::DescriptorPool#

Public Functions

explicit VulkanDescriptorPool(u32 numDescriptorSets, std::string_view name = "")#

Constructor.

Parameters:
  • numDescriptorSets – Max number of descriptor sets that can be allocated from the pool.

  • nameOptional: Name for the descriptor pool.

~VulkanDescriptorPool() override#

Destructor.

consteval VulkanDescriptorPool(const VulkanDescriptorPool&) = delete#

Copy constructor.

consteval VulkanDescriptorPool &operator=(const VulkanDescriptorPool&) = delete#

Copy assignment operator.

consteval VulkanDescriptorPool(VulkanDescriptorPool&&) = delete#

Move constructor.

consteval VulkanDescriptorPool &operator=(VulkanDescriptorPool&&) = delete#

Move assignment operator.

virtual void Reset() override#

Reset the descriptor pool.

Note

This implicitly frees all descriptor sets allocated from the pool.

constexpr VkDescriptorPool GetCurrentVkDescriptorPool() const noexcept#

Retrieve the current VkDescriptorPool handle.

Returns:

VkDescriptorPool handle.

constexpr const std::vector<VkDescriptorPoolSize> &GetDescriptorPoolSizes() const noexcept#

Retrieve the descriptor pool sizes for each descriptor type.

Returns:

Descriptor pool sizes.

constexpr u32 GetUsedDescriptorSetsCount() const noexcept#

Retrieve the count of used descriptor sets.

Returns:

Count of used descriptor sets.

virtual TRAP::Scope<DescriptorSet> RetrieveDescriptorSet(const RendererAPI::DescriptorSetDesc &desc) override#

Retrieve a new descriptor set from description.

Parameters:

desc – Descriptor set description.

Returns:

New descriptor set.

VkDescriptorSet RetrieveVkDescriptorSet(VkDescriptorSetLayout layout)#

Retrieve a new VkDescriptorSet with the given layout.

Parameters:

layout – Descriptor set layout.

Returns:

VkDescriptorSet handle.