Enumeration Case

MTLPixelFormat.bgr10_xr

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

Declaration

case bgr10_xr = 554

Discussion

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

Bit layout diagram showing the pixel data storage arrangement of the bgr10_xr pixel format. The blue component is stored in bits 0 to 9, the green component is stored in bits 10 to 19, the red component is stored in bits 20 to 29, and bits 30 to 31 are used as padding.

The blue, green, and red components are linearly encoded, and their values range from -0.752941 to 1.25098.

To display wide color values on devices with wide color displays, you can set this pixel format on the colorPixelFormat property of an MTKView or the pixelFormat property of a CAMetalLayer.

See Also

Extended Range and Wide Color Pixel Formats

case bgra10_xr

A 64-bit extended range pixel format with four fixed-point components: 10-bit blue, 10-bit green, 10-bit red, and 10-bit alpha.

case bgra10_xr_srgb

A 64-bit extended range pixel format with sRGB conversion and four fixed-point components: 10-bit blue, 10-bit green, 10-bit red, and 10-bit alpha.

case bgr10_xr_srgb

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

case bgr10a2Unorm

A 32-bit packed pixel format with four normalized unsigned integer components: 10-bit blue, 10-bit green, 10-bit red, and 2-bit alpha.