struct DescriptorHandle<T>
Conforms to: IComparable
Description
Represents a bindless handle to a descriptor. A descriptor handle is always an ordinary data type and can be declared in any memory location.
Generic Parameters
T: IOpaqueDescriptor
Methods
Remarks
Opaque descriptor types such as textures(Texture2D etc.), SamplerState and buffers (e.g. StructuredBuffer) can have undefined size and data representation on many targets. On platforms such as Vulkan and D3D12, descriptors are communicated to the shader code by calling the host side API to write the descriptor into a descriptor set or table, instead of directly writing bytes into an ordinary GPU accessible buffer. As a result, oapque handle types cannot be used in places that refer to a ordinary buffer location, such as as element types of a StructuredBuffer. However, a DescriptorHandle<T> stores a handle (or address) to the actual descriptor, and is always an ordinary data type that can be manipulated directly in the shader code. This gives the developer the flexibility to embed and pass around descriptor parameters throughout the code, to enable cleaner modular designs. See User Guide for more information on how to use DescriptorHandle<T> in your code.