MTL4IndirectInstanceAccelerationStructureDescriptor
Descriptor for an “indirect” instance acceleration structure that allows providing the instance count and motion transform count indirectly, through buffer references.
Declaration
class MTL4IndirectInstanceAccelerationStructureDescriptorOverview
An instance acceleration structure references other acceleration structures, and provides the ability to “instantiate” them multiple times, each one with potentially a different transformation matrix.
You specify the properties of the instances in the acceleration structure this descriptor builds by providing a buffer of structs via its instanceDescriptorBuffer property.
Compared to MTL4InstanceAccelerationStructureDescriptor, this descriptor allows you to provide the number of instances it references indirectly through a buffer reference, as well as the number of motion transforms.
This enables you to determine these counts indirectly in the GPU timeline via a compute pipeline. Metal needs only to know the maximum possible number of instances and motion transforms to support, which you specify via the maxInstanceCount and maxMotionTransformCount properties.
Use a MTLResidencySet to mark residency of all buffers and acceleration structures this descriptor references when you build this acceleration structure.
Topics
Instance Properties
See Also
Instance descriptors
MTLAccelerationStructureInstanceDescriptorMTLAccelerationStructureUserIDInstanceDescriptorMTLAccelerationStructureMotionInstanceDescriptorMTLAccelerationStructureInstanceOptionsMTLIndirectInstanceAccelerationStructureDescriptorMTLIndirectAccelerationStructureInstanceDescriptorMTLIndirectAccelerationStructureMotionInstanceDescriptor