<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "tvOS: -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLRenderPipelineState",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:objc(pl)MTLRenderPipelineState"
  },
  "title" : "MTLRenderPipelineState"
}
-->

# MTLRenderPipelineState

An interface that represents a graphics pipeline configuration for a render pass, which the pass applies to the draw commands you encode.

```
protocol MTLRenderPipelineState : MTLAllocation, Sendable
```

## Overview

The [`MTLRenderPipelineState`](/documentation/Metal/MTLRenderPipelineState) protocol is an interface that represents a specific configuration for the graphics-rendering pipeline, including which shaders it uses. Use a pipeline state to configure a render pass by calling the [`setRenderPipelineState(_:)`](/documentation/Metal/MTLRenderCommandEncoder/setRenderPipelineState(_:)) method of an [`MTLRenderCommandEncoder`](/documentation/Metal/MTLRenderCommandEncoder) instance.

To create a pipeline state, call the appropriate [`MTLDevice`](/documentation/Metal/MTLDevice) method (see [Pipeline state creation](/documentation/Metal/pipeline-state-creation)). You typically make pipeline states at a noncritical time, like when the app first launches. This is because graphics drivers may need time to evaluate and build each pipeline state. However, you can quickly use and reuse each pipeline state throughout your app’s lifetime.

## Topics

### Identifying a pipeline state

[`device`](/documentation/Metal/MTLRenderPipelineState/device)

The device instance that creates the pipeline state.

[`label`](/documentation/Metal/MTLRenderPipelineState/label)

A string that helps you identify the render pipeline state during debugging.

[`gpuResourceID`](/documentation/Metal/MTLRenderPipelineState/gpuResourceID)

An unique identifier that represents the pipeline state, which you can add to an argument buffer.

### Checking object shader memory requirements

[`maxTotalThreadsPerObjectThreadgroup`](/documentation/Metal/MTLRenderPipelineState/maxTotalThreadsPerObjectThreadgroup)

The largest number of threads the pipeline state can have in a single object shader threadgroup.

[`objectThreadExecutionWidth`](/documentation/Metal/MTLRenderPipelineState/objectThreadExecutionWidth)

The number of threads the render pass applies to a SIMD group for an object shader.

### Checking mesh shader memory requirements

[`maxTotalThreadsPerMeshThreadgroup`](/documentation/Metal/MTLRenderPipelineState/maxTotalThreadsPerMeshThreadgroup)

The largest number of threads the pipeline state can have in a single mesh shader threadgroup.

[`maxTotalThreadgroupsPerMeshGrid`](/documentation/Metal/MTLRenderPipelineState/maxTotalThreadgroupsPerMeshGrid)

The largest number of threadgroups the pipeline state can have in a single mesh shader grid.

[`meshThreadExecutionWidth`](/documentation/Metal/MTLRenderPipelineState/meshThreadExecutionWidth)

The number of threads the render pass applies to a SIMD group for a mesh shader.

### Checking tile shader memory requirements

[`maxTotalThreadsPerThreadgroup`](/documentation/Metal/MTLRenderPipelineState/maxTotalThreadsPerThreadgroup)

The largest number of threads the pipeline state can have in a single tile shader threadgroup.

[`threadgroupSizeMatchesTileSize`](/documentation/Metal/MTLRenderPipelineState/threadgroupSizeMatchesTileSize)

A Boolean value that indicates whether the pipeline state needs a threadgroup’s size to equal a tile’s size.

[`imageblockSampleLength`](/documentation/Metal/MTLRenderPipelineState/imageblockSampleLength)

The memory size, in byes, of the render pipeline’s imageblock for a single sample.

[`imageblockMemoryLength(forDimensions:)`](/documentation/Metal/MTLRenderPipelineState/imageblockMemoryLength(forDimensions:))

Returns the length of an imageblock’s memory for the specified imageblock dimensions.

### Checking feature support

[`supportIndirectCommandBuffers`](/documentation/Metal/MTLRenderPipelineState/supportIndirectCommandBuffers)

A Boolean value that indicates whether the render pipeline supports encoding commands into an indirect command buffer.

### Checking shader validation

[`shaderValidation`](/documentation/Metal/MTLRenderPipelineState/shaderValidation)

The current state of shader validation for the pipeline.

### Creating function handles and tables

[`functionHandle(function:stage:)`](/documentation/Metal/MTLRenderPipelineState/functionHandle(function:stage:)-7uvul)

Creates a function handle for a shader.

[`makeVisibleFunctionTable(descriptor:stage:)`](/documentation/Metal/MTLRenderPipelineState/makeVisibleFunctionTable(descriptor:stage:))

Creates a new visible function table.

[`makeIntersectionFunctionTable(descriptor:stage:)`](/documentation/Metal/MTLRenderPipelineState/makeIntersectionFunctionTable(descriptor:stage:))

Creates a new intersection function table.

### Creating modified clones of the render pipeline

[`makeRenderPipelineState(additionalBinaryFunctions:)`](/documentation/Metal/MTLRenderPipelineState/makeRenderPipelineState(additionalBinaryFunctions:)-84te1)

Creates a new pipeline state that’s a copy of the current pipeline state with additional shaders.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)