pub struct PersistentDescriptorSet<L, R, P = StdDescriptorPoolAlloc> { /* private fields */ }
Expand description

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

Creating a persistent descriptor set allocates from a pool, and can’t be modified once created. You are therefore encouraged to create them at initialization and not the during performance-critical paths.

Note: You can control of the pool that is used to create the descriptor set, if you wish so. By creating a implementation of the DescriptorPool trait that doesn’t perform any actual allocation, you can skip this allocation and make it acceptable to use a persistent descriptor set in performance-critical paths..

The template parameter of the PersistentDescriptorSet is complex, and you shouldn’t try to express it explicitly. If you want to store your descriptor set in a struct or in a Vec for example, you are encouraged to turn the PersistentDescriptorSet into a Box<DescriptorSet> or a Arc<DescriptorSet>.

Example

Implementations

Starts the process of building a PersistentDescriptorSet. Returns a builder.

Panic
  • Panics if the set id is out of range.

Trait Implementations

Returns the inner UnsafeDescriptorSet.
Returns the number of buffers within this descriptor set.
Returns the indexth buffer of this descriptor set, or None if out of range. Also returns the index of the descriptor that uses this buffer. Read more
Returns the number of images within this descriptor set.
Returns the indexth image of this descriptor set, or None if out of range. Also returns the index of the descriptor that uses this image. Read more
Returns the number of binding slots in the set.
Returns a description of a descriptor, or None if out of range.
Returns the device that owns Self.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
Builds a pointer to this type from a raw pointer.
Returns true if the size is suitable to store a type like this.
Returns the size of an individual element.
Returns the number of descriptors in the set. Includes possibly empty descriptors. Read more
Returns the descriptor for the given binding of the given set. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.