MPSTriangleAccelerationStructure(3)

NAME
MPSTriangleAccelerationStructure

SYNOPSIS

#import <MPSTriangleAccelerationStructure.h>

Inherits MPSAccelerationStructure.

  Properties
id< MTLBuffer > _Nullable vertexBuffer
Vertex buffer containing vertex data encoded as three 32 bit floats per vertex. Note that by default each vertex is aligned to the alignment of the vector_float3 type: 16 bytes. This can be changed using the vertexStride property. A vertex buffer must be provided before the acceleration structure is built. Degenerate (zero or negative area) triangles are ignored during acceleration structure construction. This can be used to pad triangle indices if needed.
NSUInteger vertexBufferOffset
Offset, in bytes, into the vertex buffer. Defaults to 0 bytes. Must be aligned to 4 bytes.
NSUInteger vertexStride
Offset, in bytes, between consecutive vertices in the vertex buffer. Defaults to 0 bytes, indicating that the vertices are packed according to the natural alignment of the vector_float3 type: 16 bytes.
id< MTLBuffer > _Nullable indexBuffer
Index buffer containing index data encoded as uint32_t per index. Each index references a vertex in the vertex buffer. May be nil.
MPSDataType indexType
Index type. Defaults to MPSDataTypeUInt32. Only MPSDataTypeUInt16 and MPSDataTypeUInt32 are supported.
NSUInteger indexBufferOffset
Offset, in bytes, into the index buffer. Defaults to 0 bytes. Must be aligned to a multiple of the index type. Changes to this property require rebuilding the acceleration structure.
id< MTLBuffer > _Nullable maskBuffer
Mask buffer containing one uint32_t mask per triangle. May be nil. Otherwise, the mask type must be specified on the MPSRayIntersector with which it is used.
NSUInteger maskBufferOffset
Offset, in bytes, into the mask buffer. Defaults to 0 bytes. Must be aligned to 4 bytes.
NSUInteger triangleCount
Number of triangles. Changes to this property require rebuilding the acceleration structure.

  Additional Inherited Members

Property Documentation

  - (id<MTLBuffer> _Nullable) indexBuffer [read], [write], [nonatomic], [retain]

Index buffer containing index data encoded as uint32_t per index. Each index references a vertex in the vertex buffer. May be nil.

  - (NSUInteger) indexBufferOffset [read], [write], [nonatomic], [assign]

Offset, in bytes, into the index buffer. Defaults to 0 bytes. Must be aligned to a multiple of the index type. Changes to this property require rebuilding the acceleration structure.

  - (MPSDataType) indexType [read], [write], [nonatomic], [assign]

Index type. Defaults to MPSDataTypeUInt32. Only MPSDataTypeUInt16 and MPSDataTypeUInt32 are supported.

  - (id<MTLBuffer> _Nullable) maskBuffer [read], [write], [nonatomic], [retain]

Mask buffer containing one uint32_t mask per triangle. May be nil. Otherwise, the mask type must be specified on the MPSRayIntersector with which it is used.

  - (NSUInteger) maskBufferOffset [read], [write], [nonatomic], [assign]

Offset, in bytes, into the mask buffer. Defaults to 0 bytes. Must be aligned to 4 bytes.

  - (NSUInteger) triangleCount [read], [write], [nonatomic], [assign]

Number of triangles. Changes to this property require rebuilding the acceleration structure.

  - (id<MTLBuffer> _Nullable) vertexBuffer [read], [write], [nonatomic], [retain]

Vertex buffer containing vertex data encoded as three 32 bit floats per vertex. Note that by default each vertex is aligned to the alignment of the vector_float3 type: 16 bytes. This can be changed using the vertexStride property. A vertex buffer must be provided before the acceleration structure is built. Degenerate (zero or negative area) triangles are ignored during acceleration structure construction. This can be used to pad triangle indices if needed.

  - (NSUInteger) vertexBufferOffset [read], [write], [nonatomic], [assign]

Offset, in bytes, into the vertex buffer. Defaults to 0 bytes. Must be aligned to 4 bytes.

  - (NSUInteger) vertexStride [read], [write], [nonatomic], [assign]

Offset, in bytes, between consecutive vertices in the vertex buffer. Defaults to 0 bytes, indicating that the vertices are packed according to the natural alignment of the vector_float3 type: 16 bytes. This can be used to skip past any additional per-vertex data which may be stored alongside the position such as the vertex normal and texture coordinates. Must be a multiple of 4 bytes, and must be at least 12 bytes. Changes to this property require rebuilding the acceleration structure.

Author

Generated automatically by Doxygen for MetalPerformanceShaders.framework from the source code.