---
title: MTLPixelFormat.bgr10_xr
framework: metal
role: symbol
role_heading: Case
path: metal/mtlpixelformat/bgr10_xr
---

# MTLPixelFormat.bgr10_xr

A 32-bit extended-range pixel format with three fixed-point components of 10-bit blue, 10-bit green, and 10-bit red.

## Declaration

```swift
case bgr10_xr
```

## Discussion

Discussion Pixel components are in blue, green, and red order, from least significant bit to most significant bit. Bits 30 and 31 are padding, and their value is 0.

Components are linearly encoded in a transform from [0,2^10) to [-0.752941, 1.25098]. The formula used in this linear encoding is shader_float = (xr10_value - 384) / 510.0f. tip: Each UNorm8-based pixel value has an exact corresponding value in the XR10 pixel range, given by xr10_value = unorm8_value * 2 + 384. To display wide color values on devices with wide color displays, set this pixel format on the colorPixelFormat property of an MTKView or the pixelFormat property of a CAMetalLayer. note: Only devices with a wide color display can display color values outside the [0.0, 1.0] range; all other devices clamp color values to the [0.0, 1.0] range.

## See Also

### Extended range and wide color pixel formats

- [MTLPixelFormat.bgra10_xr](metal/mtlpixelformat/bgra10_xr.md)
- [MTLPixelFormat.bgra10_xr_srgb](metal/mtlpixelformat/bgra10_xr_srgb.md)
- [MTLPixelFormat.bgr10_xr_srgb](metal/mtlpixelformat/bgr10_xr_srgb.md)
