<!--
{
  "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/MTLParallelRenderCommandEncoder",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:objc(pl)MTLParallelRenderCommandEncoder"
  },
  "title" : "MTLParallelRenderCommandEncoder"
}
-->

# MTLParallelRenderCommandEncoder

An instance that splits up a single render pass so that it can be simultaneously encoded from multiple threads.

```
protocol MTLParallelRenderCommandEncoder : MTLCommandEncoder
```

## Overview

Your app does not define classes that implement this protocol. To create an [`MTLParallelRenderCommandEncoder`](/documentation/Metal/MTLParallelRenderCommandEncoder) instance, call the [`makeParallelRenderCommandEncoder(descriptor:)`](/documentation/Metal/MTLCommandBuffer/makeParallelRenderCommandEncoder(descriptor:)) method of the [`MTLCommandBuffer`](/documentation/Metal/MTLCommandBuffer) instance that you want to encode the rendering commands into. Then, call the renderCommandEncoder method on this [`MTLParallelRenderCommandEncoder`](/documentation/Metal/MTLParallelRenderCommandEncoder) instance to create one or more [`MTLRenderCommandEncoder`](/documentation/Metal/MTLRenderCommandEncoder) instances. The subordinate [`MTLRenderCommandEncoder`](/documentation/Metal/MTLRenderCommandEncoder) instances created encode their commands to the same command buffer and target the same [`MTLRenderPassAttachmentDescriptor`](/documentation/Metal/MTLRenderPassAttachmentDescriptor) instance. The [`MTLParallelRenderCommandEncoder`](/documentation/Metal/MTLParallelRenderCommandEncoder) instance ensures the attachment load and store actions only occur at the start and end of the entire rendering pass.

You can assign each [`MTLRenderCommandEncoder`](/documentation/Metal/MTLRenderCommandEncoder) to its own thread and each can encode commands in parallel. You are responsible for any thread synchronization that is required. After all the subordinate encoders have finished encoding their commands, call [`endEncoding()`](/documentation/Metal/MTLCommandEncoder/endEncoding()) to execute the commands. The rendering commands are executed in the order that the subordinate encoders were created.

## Topics

### Creating a render command encoder

[`makeRenderCommandEncoder()`](/documentation/Metal/MTLParallelRenderCommandEncoder/makeRenderCommandEncoder())

Create an object that encodes commands that perform graphics rendering operations and may be assigned to a different thread.

### Setting render pass state

[`setColorStoreAction(_:index:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setColorStoreAction(_:index:))

Specifies a known store action to replace the initial [`MTLStoreAction.unknown`](/documentation/Metal/MTLStoreAction/unknown) value specified for a given color attachment.

[`setColorStoreActionOptions(_:index:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setColorStoreActionOptions(_:index:))

Specifies known store action options for a given color attachment.

[`setDepthStoreAction(_:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setDepthStoreAction(_:))

Specifies a known store action to replace the initial [`MTLStoreAction.unknown`](/documentation/Metal/MTLStoreAction/unknown) value specified for a given depth attachment.

[`setDepthStoreActionOptions(_:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setDepthStoreActionOptions(_:))

Specifies known store action options for a given depth attachment.

[`setStencilStoreAction(_:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setStencilStoreAction(_:))

Specifies a known store action to replace the initial [`MTLStoreAction.unknown`](/documentation/Metal/MTLStoreAction/unknown) value specified for a given stencil attachment.

[`setStencilStoreActionOptions(_:)`](/documentation/Metal/MTLParallelRenderCommandEncoder/setStencilStoreActionOptions(_:))

Specifies known store action options for a given stencil attachment.



---

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)