---
title: fragmentBuffers
framework: metal
role: symbol
role_heading: Instance Property
path: metal/mtlrenderpipelinedescriptor/fragmentbuffers
---

# fragmentBuffers

An array that contains the buffer mutability options for a render pipeline’s fragment function.

## Declaration

```swift
var fragmentBuffers: MTLPipelineBufferDescriptorArray { get }
```

## Discussion

Discussion This property returns an array of MTLPipelineBufferDescriptor instances, where each element corresponds to the index in the buffer argument table for the render pipeline’s fragment function. // Indicate the fragment buffer at index 8 is immutable while setting up the render pipeline. MTLRenderPipelineDescriptor *renderDescriptor = [MTLRenderPipelineDescriptor new]; renderDescriptor.fragmentBuffers[8].mutability = MTLMutabilityImmutable;

// Create an encoder for the render pass. id <MTLRenderCommandEncoder> renderEncoder; renderEncoder = [_commandBuffer renderCommandEncoderWithDescriptor:_renderPassDescriptor];

// Assign the buffer at index 8 for the render pass. [renderEncoder setFragmentBuffer:_buffer offset:0 atIndex:8];

## See Also

### Specifying buffer mutability

- [vertexBuffers](metal/mtlrenderpipelinedescriptor/vertexbuffers.md)
