Linux 4.8.3
[linux/fpc-iii.git] / Documentation / media / uapi / v4l / pixfmt-yuv422p.rst
blob9f34762adf1801483b6b10a5387ecc50a87c9ccb
1 .. -*- coding: utf-8; mode: rst -*-
3 .. _V4L2-PIX-FMT-YUV422P:
5 *****************************
6 V4L2_PIX_FMT_YUV422P ('422P')
7 *****************************
9 *man V4L2_PIX_FMT_YUV422P(2)*
11 Format with ½ horizontal chroma resolution, also known as YUV 4:2:2.
12 Planar layout as opposed to ``V4L2_PIX_FMT_YUYV``
15 Description
16 ===========
18 This format is not commonly used. This is a planar version of the YUYV
19 format. The three components are separated into three sub-images or
20 planes. The Y plane is first. The Y plane has one byte per pixel. The Cb
21 plane immediately follows the Y plane in memory. The Cb plane is half
22 the width of the Y plane (and of the image). Each Cb belongs to two
23 pixels. For example, Cb\ :sub:`0` belongs to Y'\ :sub:`00`,
24 Y'\ :sub:`01`. Following the Cb plane is the Cr plane, just like the Cb
25 plane.
27 If the Y plane has pad bytes after each row, then the Cr and Cb planes
28 have half as many pad bytes after their rows. In other words, two Cx
29 rows (including padding) is exactly as long as one Y row (including
30 padding).
32 **Byte Order.**
33 Each cell is one byte.
37 .. flat-table::
38     :header-rows:  0
39     :stub-columns: 0
40     :widths:       2 1 1 1 1
43     -  .. row 1
45        -  start + 0:
47        -  Y'\ :sub:`00`
49        -  Y'\ :sub:`01`
51        -  Y'\ :sub:`02`
53        -  Y'\ :sub:`03`
55     -  .. row 2
57        -  start + 4:
59        -  Y'\ :sub:`10`
61        -  Y'\ :sub:`11`
63        -  Y'\ :sub:`12`
65        -  Y'\ :sub:`13`
67     -  .. row 3
69        -  start + 8:
71        -  Y'\ :sub:`20`
73        -  Y'\ :sub:`21`
75        -  Y'\ :sub:`22`
77        -  Y'\ :sub:`23`
79     -  .. row 4
81        -  start + 12:
83        -  Y'\ :sub:`30`
85        -  Y'\ :sub:`31`
87        -  Y'\ :sub:`32`
89        -  Y'\ :sub:`33`
91     -  .. row 5
93        -  start + 16:
95        -  Cb\ :sub:`00`
97        -  Cb\ :sub:`01`
99     -  .. row 6
101        -  start + 18:
103        -  Cb\ :sub:`10`
105        -  Cb\ :sub:`11`
107     -  .. row 7
109        -  start + 20:
111        -  Cb\ :sub:`20`
113        -  Cb\ :sub:`21`
115     -  .. row 8
117        -  start + 22:
119        -  Cb\ :sub:`30`
121        -  Cb\ :sub:`31`
123     -  .. row 9
125        -  start + 24:
127        -  Cr\ :sub:`00`
129        -  Cr\ :sub:`01`
131     -  .. row 10
133        -  start + 26:
135        -  Cr\ :sub:`10`
137        -  Cr\ :sub:`11`
139     -  .. row 11
141        -  start + 28:
143        -  Cr\ :sub:`20`
145        -  Cr\ :sub:`21`
147     -  .. row 12
149        -  start + 30:
151        -  Cr\ :sub:`30`
153        -  Cr\ :sub:`31`
156 **Color Sample Location..**
160 .. flat-table::
161     :header-rows:  0
162     :stub-columns: 0
165     -  .. row 1
167        -
168        -  0
170        -
171        -  1
173        -  2
175        -
176        -  3
178     -  .. row 2
180        -  0
182        -  Y
184        -  C
186        -  Y
188        -  Y
190        -  C
192        -  Y
194     -  .. row 3
196        -  1
198        -  Y
200        -  C
202        -  Y
204        -  Y
206        -  C
208        -  Y
210     -  .. row 4
212        -  2
214        -  Y
216        -  C
218        -  Y
220        -  Y
222        -  C
224        -  Y
226     -  .. row 5
228        -  3
230        -  Y
232        -  C
234        -  Y
236        -  Y
238        -  C
240        -  Y