Contents

MTLArgument

Information about an argument of a graphics or compute function.

Declaration

class MTLArgument

Overview

An MTLArgument instance describes a single argument to a Metal function. Your app uses the MTLArgument properties to read details about a function argument as it was defined in the Metal Shading Language. You can determine the argument’s data type, access restrictions, and its associated resource type. For buffer, texture, and threadgroup memory arguments, additional properties can be read to determine more details about the argument.

Your app does not create an MTLArgument instance directly. Creating an MTLRenderPipelineState or MTLComputePipelineState instance can generate a reflection instance (MTLRenderPipelineReflection or MTLComputePipelineReflection) that contains MTLArgument instances.

Topics

Describing the argument

Describing a buffer argument

Describing a texture argument

Describing an array argument

Describing a threadgroup memory argument

See Also

Function arguments