[][src]Module vulkano::descriptor::descriptor_set

Descriptor sets creation and management

This module is dedicated to managing descriptor sets. There are three concepts in Vulkan related to descriptor sets:

  • A DescriptorSetLayout is a Vulkan object that describes to the Vulkan implementation the layout of a future descriptor set. When you allocate a descriptor set, you have to pass an instance of this object. This is represented with the UnsafeDescriptorSetLayout type in vulkano.
  • A DescriptorPool is a Vulkan object that holds the memory of descriptor sets and that can be used to allocate and free individual descriptor sets. This is represented with the UnsafeDescriptorPool type in vulkano.
  • A DescriptorSet contains the bindings to resources and is allocated from a pool. This is represented with the UnsafeDescriptorSet type in vulkano.

In addition to this, vulkano defines the following:

  • The DescriptorPool trait can be implemented on types from which you can allocate and free descriptor sets. However it is different from Vulkan descriptor pools in the sense that an implementation of the DescriptorPool trait can manage multiple Vulkan descriptor pools.
  • The StdDescriptorPool type is a default implementation of the DescriptorPool trait.
  • The DescriptorSet trait is implemented on types that wrap around Vulkan descriptor sets in a safe way. A Vulkan descriptor set is inherently unsafe, so we need safe wrappers around them.
  • The SimpleDescriptorSet type is a default implementation of the DescriptorSet trait.
  • The DescriptorSetsCollection trait is implemented on collections of types that implement DescriptorSet. It is what you pass to the draw functions.

Re-exports

pub use self::collection::DescriptorSetsCollection;

Modules

collection

Structs

DescriptorWrite

Represents a single write entry to a descriptor set.

DescriptorsCount

Number of available descriptors slots in a pool.

FixedSizeDescriptorSet

A descriptor set created from a FixedSizeDescriptorSetsPool.

FixedSizeDescriptorSetBuilder

Prototype of a FixedSizeDescriptorSet.

FixedSizeDescriptorSetBuilderArray

Same as FixedSizeDescriptorSetBuilder, but we're in an array.

FixedSizeDescriptorSetsPool

Pool of descriptor sets of a specific capacity and that are automatically reclaimed.

PersistentDescriptorSet

An immutable descriptor set that is expected to be long-lived.

PersistentDescriptorSetBuf

Internal object related to the PersistentDescriptorSet system.

PersistentDescriptorSetBufView

Internal object related to the PersistentDescriptorSet system.

PersistentDescriptorSetBuilder

Prototype of a PersistentDescriptorSet.

PersistentDescriptorSetBuilderArray

Same as PersistentDescriptorSetBuilder, but we're in an array.

PersistentDescriptorSetImg

Internal object related to the PersistentDescriptorSet system.

PersistentDescriptorSetSampler

Internal object related to the PersistentDescriptorSet system.

StdDescriptorPool

Standard implementation of a descriptor pool.

StdDescriptorPoolAlloc

A descriptor set allocated from a StdDescriptorPool.

UnsafeDescriptorPool

Pool from which descriptor sets are allocated from.

UnsafeDescriptorPoolAllocIter

Iterator to the descriptor sets allocated from an unsafe descriptor pool.

UnsafeDescriptorSet

Low-level descriptor set.

UnsafeDescriptorSetLayout

Describes to the Vulkan implementation the layout of all descriptors within a descriptor set.

Enums

DescriptorPoolAllocError

Error that can be returned when creating a device.

PersistentDescriptorSetBuildError

Error when building a persistent descriptor set.

PersistentDescriptorSetError

Error related to the persistent descriptor set.

Traits

DescriptorPool

A pool from which descriptor sets can be allocated.

DescriptorPoolAlloc

An allocated descriptor set.

DescriptorSet

Trait for objects that contain a collection of resources that will be accessible by shaders.

DescriptorSetDesc

Trait for objects that describe the layout of the descriptors of a set.