<!--
{
  "availability" : [
    "macOS: 26.0.0 -",
    "visionOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CompositorServices",
  "identifier" : "/documentation/CompositorServices/cp_layer_renderer_configuration_get_drawable_render_context_stencil_format",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Compositor Services"
    ],
    "preciseIdentifier" : "c:@F@cp_layer_renderer_configuration_get_drawable_render_context_stencil_format"
  },
  "title" : "cp_layer_renderer_configuration_get_drawable_render_context_stencil_format"
}
-->

# cp_layer_renderer_configuration_get_drawable_render_context_stencil_format

Returns the pixel format to use for the stencil texture in drawable’s render context.

```
MTLPixelFormat cp_layer_renderer_configuration_get_drawable_render_context_stencil_format(cp_layer_renderer_configuration_t configuration);
```

## Parameters

`configuration`

The layer configuration type that contains the
information. The system passes an instance of this type to the
[`makeConfiguration(capabilities:configuration:)`](/documentation/CompositorServices/CompositorLayerConfiguration/makeConfiguration(capabilities:configuration:))
method of your configuration provider.

## Return Value

The pixel format to use for the drawable’s render context stencil textures.

---

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)