Name

V4L2_PIX_FMT_YUYV — Packed format with ½ horizontal chroma resolution, also known as YUV 4:2:2

Description

In this format each four bytes is two pixels. Each four bytes is two Y's, a Cb and a Cr. Each Y goes to one of the pixels, and the Cb and Cr belong to both pixels. As you can see, the Cr and Cb components have half the horizontal resolution of the Y component. V4L2_PIX_FMT_YUYV is known in the Windows environment as YUY2.

Example 2.9. V4L2_PIX_FMT_YUYV 4 × 4 pixel image

Byte Order. Each cell is one byte.

start + 0:Y'00Cb00Y'01Cr00Y'02Cb01Y'03Cr01
start + 8:Y'10Cb10Y'11Cr10Y'12Cb11Y'13Cr11
start + 16:Y'20Cb20Y'21Cr20Y'22Cb21Y'23Cr21
start + 24:Y'30Cb30Y'31Cr30Y'32Cb31Y'33Cr31

Color Sample Location. 

 0 1 2 3
0YCY YCY
1YCY YCY
2YCY YCY
3YCY YCY