---
title: "init(colorPixelFormat:depthPixelFormat:)"
framework: realitykit
role: symbol
role_heading: Initializer
path: "realitykit/lowlevelrenderer/configuration/output-swift.struct/init(colorpixelformat:depthpixelformat:)"
---

# init(colorPixelFormat:depthPixelFormat:)

Creates an output configuration with the given color and depth pixel formats.

## Declaration

```swift
init(colorPixelFormat: MTLPixelFormat?, depthPixelFormat: MTLPixelFormat? = nil)
```

## Parameters

- `colorPixelFormat`: The pixel format of the color attachment, or nil for depth-only passes.
- `depthPixelFormat`: The pixel format of the depth attachment, or nil to omit depth. Defaults to nil.
