2.6.1. Packed YUV formats

2.6.1.1. Description

Similar to the packed RGB formats these formats store the Y, Cb and Cr component of each pixel in one 16 or 32 bit word.

Packed YUV Image Formats
Identifier Code Byte 0 in memory Byte 1 Byte 2 Byte 3
    7 6 5 4 3 2 1 0 7 6 5 4 3 2 1 0 7 6 5 4 3 2 1 0 7 6 5 4 3 2 1 0
V4L2_PIX_FMT_YUV444 ‘Y444’ Cb3 Cb2 Cb1 Cb0 Cr3 Cr2 Cr1 Cr0 a3 a2 a1 a0 Y’3 Y’2 Y’1 Y’0

V4L2_PIX_FMT_YUV555 ‘YUVO’ Cb2 Cb1 Cb0 Cr4 Cr3 Cr2 Cr1 Cr0 a Y’4 Y’3 Y’2 Y’1 Y’0 Cb4 Cb3

V4L2_PIX_FMT_YUV565 ‘YUVP’ Cb2 Cb1 Cb0 Cr4 Cr3 Cr2 Cr1 Cr0 Y’4 Y’3 Y’2 Y’1 Y’0 Cb5 Cb4 Cb3

V4L2_PIX_FMT_YUV32 ‘YUV4’ a7 a6 a5 a4 a3 a2 a1 a0 Y’7 Y’6 Y’5 Y’4 Y’3 Y’2 Y’1 Y’0 Cb7 Cb6 Cb5 Cb4 Cb3 Cb2 Cb1 Cb0 Cr7 Cr6 Cr5 Cr4 Cr3 Cr2 Cr1

Cr0

V4L2_PIX_FMT_AYUV32 ‘AYUV’ a7 a6 a5 a4 a3 a2 a1 a0 Y’7 Y’6 Y’5 Y’4 Y’3 Y’2 Y’1 Y’0 Cb7 Cb6 Cb5 Cb4 Cb3 Cb2 Cb1 Cb0 Cr7 Cr6 Cr5 Cr4 Cr3 Cr2 Cr1

Cr0

V4L2_PIX_FMT_XYUV32 ‘XYUV’ Y’7 Y’6 Y’5 Y’4 Y’3 Y’2 Y’1 Y’0 Cb7 Cb6 Cb5 Cb4 Cb3 Cb2 Cb1 Cb0 Cr7 Cr6 Cr5 Cr4 Cr3 Cr2 Cr1

Cr0

V4L2_PIX_FMT_VUYA32 ‘VUYA’ Cr7 Cr6 Cr5 Cr4 Cr3 Cr2 Cr1 Cr0 Cb7 Cb6 Cb5 Cb4 Cb3 Cb2 Cb1 Cb0 Y’7 Y’6 Y’5 Y’4 Y’3 Y’2 Y’1 Y’0 a7 a6 a5 a4 a3 a2 a1

a0

V4L2_PIX_FMT_VUYX32 ‘VUYX’ Cr7 Cr6 Cr5 Cr4 Cr3 Cr2 Cr1 Cr0 Cb7 Cb6 Cb5 Cb4 Cb3 Cb2 Cb1 Cb0 Y’7 Y’6 Y’5 Y’4 Y’3 Y’2 Y’1 Y’0

Note

  1. Bit 7 is the most significant bit;
  2. The value of a = alpha bits is undefined when reading from the driver, ignored when writing to the driver, except when alpha blending has been negotiated for a Video Overlay or Video Output Overlay for the formats Y444, YUV555 and YUV4. However, for formats AYUV32 and VUYA32, the alpha component is expected to contain a meaningful value that can be used by drivers and applications. And, the formats XYUV32 and VUYX32 contain undefined alpha values that must be ignored by all applications and drivers.