Instance Property


The minimum region entirely enclosing the mesh’s vertex positions, expressed in the model coordinate system of the mesh.


@property(nonatomic, readonly) MDLAxisAlignedBoundingBox boundingBox;


This property’s value is valid only if the mesh contains vertex data for the MDLVertexAttributePosition attribute. If the mesh does not contain position information, this property’s value is a bounding box whose maxBounds coordinate is greater than its minBounds coordinate.

Reading this property for the first time processes the mesh’s vertex data to calculate and cache a bounding box. Reading this property thereafter returns the cached value.

See Also

Working with Vertex Data


The array of submeshes to be used in rendering the mesh.


The array of buffers that provide vertex data for the mesh.


The number of vertices in the mesh.


A description of the format and layout of the mesh’s vertex buffers.

- addAttributeWithName:format:

Adds a vertex attribute to the mesh and creates a new, empty corresponding vertex buffer.

- vertexAttributeDataForAttributeNamed:

Returns the vertex data for the specified attribute.