Enum ColorSpaceType
Specifies the type of color space a Graphics Presenter has to output.
public enum ColorSpaceType : uint
- Extension Methods
Fields
Custom = 4294967295A custom color definition is used.
Rgb_Full_G10_None_P709 = 1This is the linear RGB color space with BT.709 primaries. Linear gamma means no gamma correction is applied, making it suitable for HDR content and mathematical operations on color values.
It is the standard definition for scRGB, and is usually used with 16-bit integer, 16-bit floating point, and 32-bit floating point channels.
Commonly used in HDR workflows and when precise color calculations are required. Use with floating-point formats like R16G16B16A16_Float.
- Color Space: RGB
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 1.0 (Linear)
- Siting: Image
- Primaries: BT.709
Rgb_Full_G2084_None_P2020 = 12This is RGB with Perceptual Quantizer (PQ) transfer function and BT.2020 primaries. PQ (ST-2084) is designed for HDR content and can represent brightness levels up to 10,000 nits.
Used for HDR10 content and high dynamic range applications. Requires HDR-capable displays and processing. Common with formats like R10G10B10A2_UNorm. It is usually used with 10 or 12-bit color channels.
- Color Space: RGB
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: ST-2084 (PQ)
- Siting: Image
- Primaries: BT.2020
Rgb_Full_G22_None_P2020 = 17This is RGB with wide color gamut BT.2020 primaries and traditional gamma 2.2. Provides wider color gamut than BT.709 while maintaining compatibility with SDR workflows.
It is usually used with 10 or 12-bit color channels.
Used for wide color gamut content that doesn't require HDR transfer functions. Suitable for displays capable of BT.2020 color reproduction.
- Color Space: RGB
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Image
- Primaries: BT.2020
Rgb_Full_G22_None_P709 = 0This is the standard definition for sRGB. Note that this is often implemented with a linear segment, but in that case, the exponent is corrected to stay aligned with a gamma 2.2 curve.
This is usually used with 8-bit and 10-bit color channels. Use with 8-bit-per-channel Back-Buffers formats, such as B8G8R8A8_UNorm.
- Color Space: RGB
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Image
- Primaries: BT.709
Rgb_Studio_G2084_None_P2020 = 14This is RGB with Perceptual Quantizer (PQ) transfer function, studio range, and BT.2020 primaries. Studio range provides headroom for HDR processing while maintaining compatibility with broadcast standards.
It is usually used with 10 or 12-bit color channels.
Used in professional HDR workflows where studio range is required for broadcast compatibility.
- Color Space: RGB
- Range: Studio (16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit)
- Gamma: ST-2084 (PQ)
- Siting: Image
- Primaries: BT.2020
Rgb_Studio_G22_None_P2020 = 3This is RGB with studio range and wide color gamut BT.2020 primaries. BT.2020 provides a much wider color gamut than BT.709, supporting more vivid and saturated colors.
It is usually used with 10 or 12-bit color channels.
Used in Ultra HD (4K) and HDR content production. Requires displays capable of wide color gamut reproduction.
- Color Space: RGB
- Range: Studio (16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit)
- Gamma: 2.2
- Siting: Image
- Primaries: BT.2020
Rgb_Studio_G22_None_P709 = 2This is RGB with studio/limited range, commonly used in broadcast and professional video production. The limited range reserves headroom and footroom for video processing.
It is the standard definition for ITU-R Recommendation BT.709. Note that due to the inclusion of a linear segment, the transfer curve looks similar to a pure exponential gamma of 1.9. This is usually used with 8-bit and 10-bit color channels.
Typically used in broadcast workflows and professional video applications where studio range is required.
- Color Space: RGB
- Range: Studio (16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit)
- Gamma: 2.2
- Siting: Image
- Primaries: BT.709
Rgb_Studio_G24_None_P2020 = 21This is RGB with gamma 2.4 transfer function, studio range, and wide color gamut BT.2020 primaries. Combines precise gamma 2.4 with wide color gamut for professional workflows.
It is usually used with 10 or 12-bit color channels.
Used in professional wide color gamut workflows where gamma 2.4 is specified.
- Color Space: RGB
- Range: Studio (16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit)
- Gamma: 2.4
- Siting: Image
- Primaries: BT.2020
Rgb_Studio_G24_None_P709 = 20This is RGB with gamma 2.4 transfer function, studio range, and BT.709 primaries. Gamma 2.4 is used in some professional and cinema workflows for more precise color reproduction.
It is usually used with 8, 10, or 12-bit color channels.
Used in professional video production and cinema workflows where gamma 2.4 is specified.
- Color Space: RGB
- Range: Studio (16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit)
- Gamma: 2.4
- Siting: Image
- Primaries: BT.709
YCbCr_Full_G22_Left_P2020 = 11This is YCbCr with full range and wide color gamut BT.2020 primaries. Full range provides better bit depth utilization while BT.2020 enables wide color gamut reproduction.
It is usually used with 10, 12, or 16-bit color channels.
Used in wide color gamut applications where full range precision is desired.
- Color Space: YCbCr
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.2020
YCbCr_Full_G22_Left_P601 = 7This is YCbCr with full range and BT.601 primaries. Full range utilizes the complete bit depth available, providing slightly better precision than studio range.
It is usually used with 8, 10, 12, or 16-bit color channels.
Sometimes used in JPEG images and certain video codecs that support full range YCbCr, such as H.264 camera capture.
- Color Space: YCbCr
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.601
YCbCr_Full_G22_Left_P709 = 9This is YCbCr with full range and BT.709 primaries. Full range provides better utilization of the available bit depth compared to studio range.
It is usually used with 8, 10, 12, or 16-bit color channels.
Used in some video codecs and applications that prefer full range for better precision. Sometimes used for H.264 camera capture.
- Color Space: YCbCr
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.709
YCbCr_Full_G22_None_P709_X601 = 5This is YCbCr with full range using BT.709 primaries but BT.601 matrix coefficients. This combination is sometimes used for compatibility reasons in certain legacy workflows.
It is usually used with 8, 10, 12, or 16-bit color channels.
Less common configuration, typically found in specific legacy or compatibility scenarios, for example, it is commonly used in JPEG images and some video codecs.
- Color Space: YCbCr
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: 2.2
- Siting: Image
- Primaries: BT.709
- Transfer Matrix: BT.601
YCbCr_Full_Ghlg_Topleft_P2020 = 19This is YCbCr with Hybrid Log-Gamma (HLG) transfer function, full range, and BT.2020 primaries. Full range provides better bit depth utilization while maintaining HLG's backward compatibility.
It is usually used with 10 or 12-bit color channels.
Used in HDR applications where full range precision is desired with HLG transfer function.
- Color Space: YCbCr
- Range: Full (0-255 for 8-bit, 0-1023 for 10-bit, 0-4095 for 12-bit)
- Gamma: HLG (Hybrid Log-Gamma)
- Siting: Video (Top-Left)
- Primaries: BT.2020
YCbCr_Studio_G2084_Left_P2020 = 13This is YCbCr with Perceptual Quantizer (PQ) transfer function, studio range, and BT.2020 primaries. This is the standard color space for HDR10 video content.
It is usually used with 10, 12, or 16-bit color channels.
The primary color space for HDR10 video streams, Ultra HD Blu-ray, and HDR streaming content. Widely supported by HDR displays and media players.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: ST-2084 (PQ)
- Siting: Video (Left)
- Primaries: BT.2020
YCbCr_Studio_G2084_Topleft_P2020 = 16This is YCbCr with Perceptual Quantizer (PQ) transfer function, BT.2020 primaries, and top-left chroma siting. Combines HDR capabilities with specific chroma siting requirements.
It is usually used with 10, 12, or 16-bit color channels.
Used in HDR video processing where top-left chroma siting is specifically required.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: ST-2084 (PQ)
- Siting: Video (Top-Left)
- Primaries: BT.2020
YCbCr_Studio_G22_Left_P2020 = 10This is YCbCr with wide color gamut BT.2020 primaries and studio range. BT.2020 supports a much wider color gamut than BT.709, enabling more vivid and saturated colors.
It is usually used with 10, 12, or 16-bit color channels.
Used for Ultra HD (4K) content and wide color gamut video production. Requires compatible displays and processing pipelines, like those used in HEVC (H.265) video encoding.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.2020
YCbCr_Studio_G22_Left_P601 = 6This is the standard definition television (SDTV) color space with BT.601 primaries and matrix. Left siting means chroma samples are aligned with the left edge of luma samples.
It is usually used with 8, 10, 12, or 16-bit color channels.
Used for standard definition video content, DVDs, and legacy broadcast systems. Commonly used for MPEG2. It is ususally used with formats like
NV12.- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.601
YCbCr_Studio_G22_Left_P709 = 8This is the standard high definition television (HDTV) color space with BT.709 primaries. This is the most common color space for HD video content and Blu-ray discs.
It is usually used with 8, 10, 12, or 16-bit color channels.
Widely used for HD video content, streaming, and broadcast television. Compatible with most HD video formats and codecs, like H.264 and HEVC.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.2
- Siting: Video (Left)
- Primaries: BT.709
YCbCr_Studio_G22_Topleft_P2020 = 15This is YCbCr with BT.2020 primaries and top-left chroma siting. Top-left siting means chroma samples are aligned with the top-left corner of the corresponding luma samples.
It is usually used with 10, 12, or 16-bit color channels.
Used in specific video processing pipelines where top-left chroma siting is required.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.2
- Siting: Video (Top-Left)
- Primaries: BT.2020
YCbCr_Studio_G24_Left_P2020 = 23This is YCbCr with gamma 2.4 transfer function, studio range, and wide color gamut BT.2020 primaries. Combines precise gamma 2.4 with wide color gamut for professional workflows.
It is usually used with 10 or 12-bit color channels.
Used in professional wide color gamut video production where gamma 2.4 is specified.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.4
- Siting: Video (Left)
- Primaries: BT.2020
YCbCr_Studio_G24_Left_P709 = 22This is YCbCr with gamma 2.4 transfer function, studio range, and BT.709 primaries. Gamma 2.4 provides more precise color reproduction in professional video workflows.
It is usually used with 8, 10, or 12-bit color channels.
Used in professional video production where gamma 2.4 is specified for HD content.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.4
- Siting: Video (Left)
- Primaries: BT.709
YCbCr_Studio_G24_Topleft_P2020 = 24This is YCbCr with gamma 2.4 transfer function, studio range, BT.2020 primaries, and top-left chroma siting. Combines precise gamma 2.4 with wide color gamut and specific chroma siting requirements.
It is usually used with 10 or 12-bit color channels.
Used in professional wide color gamut video production where gamma 2.4 and top-left chroma siting are specified.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: 2.4
- Siting: Video (Top-Left)
- Primaries: BT.2020
YCbCr_Studio_Ghlg_Topleft_P2020 = 18This is YCbCr with Hybrid Log-Gamma (HLG) transfer function and BT.2020 primaries. HLG is designed for HDR broadcasting and provides backward compatibility with SDR displays.
It is usually used with 10 or 12-bit color channels.
Used for HDR broadcasting and live TV where backward compatibility with SDR is important. Common in broadcast television and streaming services.
- Color Space: YCbCr
- Range: Studio (luma: 16-235 for 8-bit, 64-940 for 10-bit, 256-3760 for 12-bit; chroma (Cb/Cr): 16-240 for 8-bit, 64-960 for 10-bit, 256-3840 for 12-bit).
- Gamma: HLG (Hybrid Log-Gamma)
- Siting: Video (Top-Left)
- Primaries: BT.2020
Remarks
This enum is used within a Graphics Presenter when configuring a Swap Chain to check the color space support of the Graphics Adapter and the Graphics Output, set a specific color space as output of the Swap Chain. It is also referenced in D3D11 video methods
It is also used for defining the output color space of video decoding.
The constants in this enum are divided into parts that describe the following:
Color Space
Defines the color space of the color channel data.
| Rgb | The Red / Green / Blue color space color channels. |
| YCbCr | Three channel color model which splits luma (brightness) from chroma (color). YUV technically refers to analog signals and YCbCr to digital, but they are used interchangeably. |
Range
Indicates which integer range corresponds to the floating point [0..1] range of the data. For video, integer YCbCr data with ranges of [16..235] or [8..247] are usually mapped to normalized YCbCr with ranges of [0..1] or [-0.5..0.5].
| Full |
For PC desktop content and images.
Defines the ranges: For 8-bit: 0-255, for 10-bit: 0-1023, for 12-bit: 0-4095.
|
| Studio |
Often used in video. Enables the calibration of white and black between displays.
Defines the ranges: For 8-bit: 16-235, for 10-bit: 64-940, for 12-bit: 256 - 3760.
|
Gamma
| G10 | Gamma 1.0. Linear light levels. |
| G22 | Gamma 2.2. Commonly used for sRGB and BT.709 (linear segment + 2.4). |
| G24 | Gamma 2.4. Commonly used in cinema and professional video workflows. |
| G2084 | SMPTE ST.2084 (Perceptual Quantization). |
Siting
"Siting" indicates a horizontal or vertical shift of the chrominance channels relative to the luminance channel. "Cositing" indicates values are sited between pixels in the vertical or horizontal direction (also known as being "sited interstitially").
| None | For images. The U and V planes are aligned vertically. |
| Left | For video. Chroma samples are aligned horizontally with the luma samples, or with multiples of the luma samples. The U and V planes are aligned vertically. |
| TopLeft | For video. The sampling point is the top left pixel (usually of a 2x2 pixel block). Chroma samples are aligned horizontally with the luma samples, or with multiples of the luma samples. Chroma samples are also aligned vertically with the luma samples, or with multiples of the luma samples. |
Primaries
| P601 | BT.601. Standard defining digital encoding of SDTV video. |
| P709 | BT.709. Standard defining digital encoding of HDTV video. |
| P2020 | BT.2020. Standard defining ultra-high definition television (UHDTV). |
Transfer Matrix
In most cases, the transfer matrix can be determined from the primaries. For some cases it must be explicitly specified as described below:
| X601 | BT.601. Standard defining digital encoding of SDTV video. |
| X709 | BT.709. Standard defining digital encoding of HDTV video. |
| X2020 | BT.2020. Standard defining ultra-high definition television (UHDTV). |