Commit | Line | Data |
---|---|---|
5377d91f MH |
1 | .. -*- coding: utf-8; mode: rst -*- |
2 | ||
3 | .. _V4L2-PIX-FMT-M420: | |
4 | ||
5 | ************************** | |
6 | V4L2_PIX_FMT_M420 ('M420') | |
7 | ************************** | |
8 | ||
5377d91f MH |
9 | Format with ½ horizontal and vertical chroma resolution, also known as |
10 | YUV 4:2:0. Hybrid plane line-interleaved layout. | |
11 | ||
12 | ||
13 | Description | |
14 | =========== | |
15 | ||
16 | M420 is a YUV format with ½ horizontal and vertical chroma subsampling | |
17 | (YUV 4:2:0). Pixels are organized as interleaved luma and chroma planes. | |
18 | Two lines of luma data are followed by one line of chroma data. | |
19 | ||
20 | The luma plane has one byte per pixel. The chroma plane contains | |
21 | interleaved CbCr pixels subsampled by ½ in the horizontal and vertical | |
22 | directions. Each CbCr pair belongs to four pixels. For example, | |
eba9e91c | 23 | Cb\ :sub:`0`/Cr\ :sub:`0` belongs to Y'\ :sub:`00`, Y'\ :sub:`01`, |
5377d91f MH |
24 | Y'\ :sub:`10`, Y'\ :sub:`11`. |
25 | ||
26 | All line lengths are identical: if the Y lines include pad bytes so do | |
27 | the CbCr lines. | |
28 | ||
056d2ee6 | 29 | **Byte Order.** |
5377d91f MH |
30 | Each cell is one byte. |
31 | ||
32 | ||
5377d91f MH |
33 | .. flat-table:: |
34 | :header-rows: 0 | |
35 | :stub-columns: 0 | |
5377d91f MH |
36 | |
37 | ||
38 | - .. row 1 | |
39 | ||
40 | - start + 0: | |
41 | ||
42 | - Y'\ :sub:`00` | |
43 | ||
44 | - Y'\ :sub:`01` | |
45 | ||
46 | - Y'\ :sub:`02` | |
47 | ||
48 | - Y'\ :sub:`03` | |
49 | ||
50 | - .. row 2 | |
51 | ||
52 | - start + 4: | |
53 | ||
54 | - Y'\ :sub:`10` | |
55 | ||
56 | - Y'\ :sub:`11` | |
57 | ||
58 | - Y'\ :sub:`12` | |
59 | ||
60 | - Y'\ :sub:`13` | |
61 | ||
62 | - .. row 3 | |
63 | ||
64 | - start + 8: | |
65 | ||
66 | - Cb\ :sub:`00` | |
67 | ||
68 | - Cr\ :sub:`00` | |
69 | ||
70 | - Cb\ :sub:`01` | |
71 | ||
72 | - Cr\ :sub:`01` | |
73 | ||
74 | - .. row 4 | |
75 | ||
76 | - start + 16: | |
77 | ||
78 | - Y'\ :sub:`20` | |
79 | ||
80 | - Y'\ :sub:`21` | |
81 | ||
82 | - Y'\ :sub:`22` | |
83 | ||
84 | - Y'\ :sub:`23` | |
85 | ||
86 | - .. row 5 | |
87 | ||
88 | - start + 20: | |
89 | ||
90 | - Y'\ :sub:`30` | |
91 | ||
92 | - Y'\ :sub:`31` | |
93 | ||
94 | - Y'\ :sub:`32` | |
95 | ||
96 | - Y'\ :sub:`33` | |
97 | ||
98 | - .. row 6 | |
99 | ||
100 | - start + 24: | |
101 | ||
102 | - Cb\ :sub:`10` | |
103 | ||
104 | - Cr\ :sub:`10` | |
105 | ||
106 | - Cb\ :sub:`11` | |
107 | ||
108 | - Cr\ :sub:`11` | |
109 | ||
110 | ||
111 | **Color Sample Location..** | |
112 | ||
113 | ||
114 | ||
115 | .. flat-table:: | |
116 | :header-rows: 0 | |
117 | :stub-columns: 0 | |
118 | ||
119 | ||
120 | - .. row 1 | |
121 | ||
0579e6e3 | 122 | - |
5377d91f MH |
123 | - 0 |
124 | ||
0579e6e3 | 125 | - |
5377d91f MH |
126 | - 1 |
127 | ||
5377d91f MH |
128 | - 2 |
129 | ||
0579e6e3 | 130 | - |
5377d91f MH |
131 | - 3 |
132 | ||
133 | - .. row 2 | |
134 | ||
135 | - 0 | |
136 | ||
137 | - Y | |
138 | ||
0579e6e3 | 139 | - |
5377d91f MH |
140 | - Y |
141 | ||
5377d91f MH |
142 | - Y |
143 | ||
0579e6e3 | 144 | - |
5377d91f MH |
145 | - Y |
146 | ||
147 | - .. row 3 | |
148 | ||
0579e6e3 MCC |
149 | - |
150 | - | |
5377d91f MH |
151 | - C |
152 | ||
0579e6e3 MCC |
153 | - |
154 | - | |
5377d91f MH |
155 | - C |
156 | ||
0579e6e3 | 157 | - |
5377d91f MH |
158 | |
159 | - .. row 4 | |
160 | ||
161 | - 1 | |
162 | ||
163 | - Y | |
164 | ||
0579e6e3 | 165 | - |
5377d91f MH |
166 | - Y |
167 | ||
5377d91f MH |
168 | - Y |
169 | ||
0579e6e3 | 170 | - |
5377d91f MH |
171 | - Y |
172 | ||
173 | - .. row 5 | |
174 | ||
0579e6e3 | 175 | - |
5377d91f MH |
176 | |
177 | - .. row 6 | |
178 | ||
179 | - 2 | |
180 | ||
181 | - Y | |
182 | ||
0579e6e3 | 183 | - |
5377d91f MH |
184 | - Y |
185 | ||
5377d91f MH |
186 | - Y |
187 | ||
0579e6e3 | 188 | - |
5377d91f MH |
189 | - Y |
190 | ||
191 | - .. row 7 | |
192 | ||
0579e6e3 MCC |
193 | - |
194 | - | |
5377d91f MH |
195 | - C |
196 | ||
0579e6e3 MCC |
197 | - |
198 | - | |
5377d91f MH |
199 | - C |
200 | ||
0579e6e3 | 201 | - |
5377d91f MH |
202 | |
203 | - .. row 8 | |
204 | ||
205 | - 3 | |
206 | ||
207 | - Y | |
208 | ||
0579e6e3 | 209 | - |
5377d91f MH |
210 | - Y |
211 | ||
5377d91f MH |
212 | - Y |
213 | ||
0579e6e3 | 214 | - |
5377d91f | 215 | - Y |