---
name: "SDL_ChromaLocation"
section: "3type"
platform: "linux"
package: "libsdl3-doc"
version: "3.2.10+ds-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/SDL_ChromaLocation"
---

# SDL\_ChromaLocation(3type)

Colorspace chroma sample location.

## NAME

SDL\_ChromaLocation - Colorspace chroma sample location.

## HEADER FILE

Defined in SDL3/SDL\_pixels.h

## SYNOPSIS

```
#include "SDL3/SDL.h"
```

**typedef enum SDL\_ChromaLocation** **{**     **SDL\_CHROMA\_LOCATION\_NONE = 0,   /\*\*\< RGB, no chroma sampling \*/**     **SDL\_CHROMA\_LOCATION\_LEFT = 1,   /\*\*\< In MPEG-2, MPEG-4, and AVC, Cb and Cr are taken on midpoint of the left-edge of the 2x2 square. In other words, they have the same horizontal location as the top-left pixel, but is shifted one-half pixel down vertically. \*/**     **SDL\_CHROMA\_LOCATION\_CENTER = 2, /\*\*\< In JPEG/JFIF, H.261, and MPEG-1, Cb and Cr are taken at the center of the 2x2 square. In other words, they are offset one-half pixel to the right and one-half pixel down compared to the top-left pixel. \*/**     **SDL\_CHROMA\_LOCATION\_TOPLEFT = 3 /\*\*\< In HEVC for BT.2020 and BT.2100 content (in particular on Blu-rays), Cb and Cr are sampled at the same location as the group's top-left Y pixel (***co-sited",***co-located***).***\*/** **} SDL\_ChromaLocation;**

## AVAILABILITY

This enum is available since SDL 3.2.0.
