Contents

MTLArgumentDescriptor

A representation of an argument within an argument buffer.

Declaration

class MTLArgumentDescriptor

Overview

This descriptor can represent arguments within flat structures only. It can represent arrays of allowed argument buffer data types, but it cannot represent arguments within nested structures. Argument buffers with simple, flat structures can be represented by an array of MTLArgumentDescriptor instances. You can then use this array to create an MTLArgumentEncoder instance by calling the makeArgumentEncoder(arguments:) method. Argument buffers with complex, nested structures need to define their structure in Metal shading language code, which can then be directly assigned to a specific buffer index of a function. You can then use this buffer index to call the makeArgumentEncoder(bufferIndex:) method and create an MTLArgumentEncoder instance.

Topics

Setting the descriptor’s properties

See Also

Argument buffers