---
title: indexBuffer
framework: metal
role: symbol
role_heading: Instance Property
path: metal/mtlaccelerationstructuretrianglegeometrydescriptor/indexbuffer
---

# indexBuffer

A buffer that contains indices for the vertices that compose the triangle list.

## Declaration

```swift
var indexBuffer: (any MTLBuffer)? { get set }
```

## Discussion

Discussion This property can be nil, in which case the vertex data defines the triangle list implicitly. You need to store indices in a packed data format.

## See Also

### Configuring index data

- [indexType](metal/mtlaccelerationstructuretrianglegeometrydescriptor/indextype.md)
- [indexBufferOffset](metal/mtlaccelerationstructuretrianglegeometrydescriptor/indexbufferoffset.md)
