~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/Documentation/userspace-api/media/v4l/yuv-formats.rst

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /Documentation/userspace-api/media/v4l/yuv-formats.rst (Architecture i386) and /Documentation/userspace-api/media/v4l/yuv-formats.rst (Architecture sparc)


  1 .. SPDX-License-Identifier: GFDL-1.1-no-invari      1 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
  2                                                     2 
  3 .. _yuv-formats:                                    3 .. _yuv-formats:
  4                                                     4 
  5 ***********                                         5 ***********
  6 YUV Formats                                         6 YUV Formats
  7 ***********                                         7 ***********
  8                                                     8 
  9 YUV is the format native to TV broadcast and c      9 YUV is the format native to TV broadcast and composite video signals. It
 10 separates the brightness information (Y) from      10 separates the brightness information (Y) from the color information (U
 11 and V or Cb and Cr). The color information con     11 and V or Cb and Cr). The color information consists of red and blue
 12 *color difference* signals, this way the green     12 *color difference* signals, this way the green component can be
 13 reconstructed by subtracting from the brightne     13 reconstructed by subtracting from the brightness component. See
 14 :ref:`colorspaces` for conversion examples. YU     14 :ref:`colorspaces` for conversion examples. YUV was chosen because
 15 early television would only transmit brightnes     15 early television would only transmit brightness information. To add
 16 color in a way compatible with existing receiv     16 color in a way compatible with existing receivers a new signal carrier
 17 was added to transmit the color difference sig     17 was added to transmit the color difference signals.
 18                                                    18 
 19                                                    19 
 20 Subsampling                                        20 Subsampling
 21 ===========                                        21 ===========
 22                                                    22 
 23 YUV formats commonly encode images with a lowe     23 YUV formats commonly encode images with a lower resolution for the chroma
 24 components than for the luma component. This c     24 components than for the luma component. This compression technique, taking
 25 advantage of the human eye being more sensitiv     25 advantage of the human eye being more sensitive to luminance than color
 26 differences, is called chroma subsampling.         26 differences, is called chroma subsampling.
 27                                                    27 
 28 While many combinations of subsampling factors     28 While many combinations of subsampling factors in the horizontal and vertical
 29 direction are possible, common factors are 1 (     29 direction are possible, common factors are 1 (no subsampling), 2 and 4, with
 30 horizontal subsampling always larger than or e     30 horizontal subsampling always larger than or equal to vertical subsampling.
 31 Common combinations are named as follows.          31 Common combinations are named as follows.
 32                                                    32 
 33 - `4:4:4`: No subsampling                          33 - `4:4:4`: No subsampling
 34 - `4:2:2`: Horizontal subsampling by 2, no ver     34 - `4:2:2`: Horizontal subsampling by 2, no vertical subsampling
 35 - `4:2:0`: Horizontal subsampling by 2, vertic     35 - `4:2:0`: Horizontal subsampling by 2, vertical subsampling by 2
 36 - `4:1:1`: Horizontal subsampling by 4, no ver     36 - `4:1:1`: Horizontal subsampling by 4, no vertical subsampling
 37 - `4:1:0`: Horizontal subsampling by 4, vertic     37 - `4:1:0`: Horizontal subsampling by 4, vertical subsampling by 4
 38                                                    38 
 39 Subsampling the chroma component effectively c     39 Subsampling the chroma component effectively creates chroma values that can be
 40 located in different spatial locations:            40 located in different spatial locations:
 41                                                    41 
 42 - .. _yuv-chroma-centered:                         42 - .. _yuv-chroma-centered:
 43                                                    43 
 44   The subsampled chroma value may be calculate     44   The subsampled chroma value may be calculated by simply averaging the chroma
 45   value of two consecutive pixels. It effectiv     45   value of two consecutive pixels. It effectively models the chroma of a pixel
 46   sited between the two original pixels. This      46   sited between the two original pixels. This is referred to as centered or
 47   interstitially sited chroma.                     47   interstitially sited chroma.
 48                                                    48 
 49 - .. _yuv-chroma-cosited:                          49 - .. _yuv-chroma-cosited:
 50                                                    50 
 51   The other option is to subsample chroma valu     51   The other option is to subsample chroma values in a way that place them in
 52   the same spatial sites as the pixels. This m     52   the same spatial sites as the pixels. This may be performed by skipping every
 53   other chroma sample (creating aliasing artif     53   other chroma sample (creating aliasing artifacts), or with filters using an
 54   odd number of taps. This is referred to as c     54   odd number of taps. This is referred to as co-sited chroma.
 55                                                    55 
 56 The following examples show different combinat     56 The following examples show different combination of chroma siting in a 4x4
 57 image.                                             57 image.
 58                                                    58 
 59 .. flat-table:: 4:2:2 subsampling, interstitia     59 .. flat-table:: 4:2:2 subsampling, interstitially sited
 60     :header-rows: 1                                60     :header-rows: 1
 61     :stub-columns: 1                               61     :stub-columns: 1
 62                                                    62 
 63     * -                                            63     * -
 64       - 0                                          64       - 0
 65       -                                            65       -
 66       - 1                                          66       - 1
 67       -                                            67       -
 68       - 2                                          68       - 2
 69       -                                            69       -
 70       - 3                                          70       - 3
 71     * - 0                                          71     * - 0
 72       - Y                                          72       - Y
 73       - C                                          73       - C
 74       - Y                                          74       - Y
 75       -                                            75       -
 76       - Y                                          76       - Y
 77       - C                                          77       - C
 78       - Y                                          78       - Y
 79     * - 1                                          79     * - 1
 80       - Y                                          80       - Y
 81       - C                                          81       - C
 82       - Y                                          82       - Y
 83       -                                            83       -
 84       - Y                                          84       - Y
 85       - C                                          85       - C
 86       - Y                                          86       - Y
 87     * - 2                                          87     * - 2
 88       - Y                                          88       - Y
 89       - C                                          89       - C
 90       - Y                                          90       - Y
 91       -                                            91       -
 92       - Y                                          92       - Y
 93       - C                                          93       - C
 94       - Y                                          94       - Y
 95     * - 3                                          95     * - 3
 96       - Y                                          96       - Y
 97       - C                                          97       - C
 98       - Y                                          98       - Y
 99       -                                            99       -
100       - Y                                         100       - Y
101       - C                                         101       - C
102       - Y                                         102       - Y
103                                                   103 
104 .. flat-table:: 4:2:2 subsampling, co-sited       104 .. flat-table:: 4:2:2 subsampling, co-sited
105     :header-rows: 1                               105     :header-rows: 1
106     :stub-columns: 1                              106     :stub-columns: 1
107                                                   107 
108     * -                                           108     * -
109       - 0                                         109       - 0
110       -                                           110       -
111       - 1                                         111       - 1
112       -                                           112       -
113       - 2                                         113       - 2
114       -                                           114       -
115       - 3                                         115       - 3
116     * - 0                                         116     * - 0
117       - Y/C                                       117       - Y/C
118       -                                           118       -
119       - Y                                         119       - Y
120       -                                           120       -
121       - Y/C                                       121       - Y/C
122       -                                           122       -
123       - Y                                         123       - Y
124     * - 1                                         124     * - 1
125       - Y/C                                       125       - Y/C
126       -                                           126       -
127       - Y                                         127       - Y
128       -                                           128       -
129       - Y/C                                       129       - Y/C
130       -                                           130       -
131       - Y                                         131       - Y
132     * - 2                                         132     * - 2
133       - Y/C                                       133       - Y/C
134       -                                           134       -
135       - Y                                         135       - Y
136       -                                           136       -
137       - Y/C                                       137       - Y/C
138       -                                           138       -
139       - Y                                         139       - Y
140     * - 3                                         140     * - 3
141       - Y/C                                       141       - Y/C
142       -                                           142       -
143       - Y                                         143       - Y
144       -                                           144       -
145       - Y/C                                       145       - Y/C
146       -                                           146       -
147       - Y                                         147       - Y
148                                                   148 
149 .. flat-table:: 4:2:0 subsampling, horizontall    149 .. flat-table:: 4:2:0 subsampling, horizontally interstitially sited, vertically co-sited
150     :header-rows: 1                               150     :header-rows: 1
151     :stub-columns: 1                              151     :stub-columns: 1
152                                                   152 
153     * -                                           153     * -
154       - 0                                         154       - 0
155       -                                           155       -
156       - 1                                         156       - 1
157       -                                           157       -
158       - 2                                         158       - 2
159       -                                           159       -
160       - 3                                         160       - 3
161     * - 0                                         161     * - 0
162       - Y                                         162       - Y
163       - C                                         163       - C
164       - Y                                         164       - Y
165       -                                           165       -
166       - Y                                         166       - Y
167       - C                                         167       - C
168       - Y                                         168       - Y
169     * - 1                                         169     * - 1
170       - Y                                         170       - Y
171       -                                           171       -
172       - Y                                         172       - Y
173       -                                           173       -
174       - Y                                         174       - Y
175       -                                           175       -
176       - Y                                         176       - Y
177     * - 2                                         177     * - 2
178       - Y                                         178       - Y
179       - C                                         179       - C
180       - Y                                         180       - Y
181       -                                           181       -
182       - Y                                         182       - Y
183       - C                                         183       - C
184       - Y                                         184       - Y
185     * - 3                                         185     * - 3
186       - Y                                         186       - Y
187       -                                           187       -
188       - Y                                         188       - Y
189       -                                           189       -
190       - Y                                         190       - Y
191       -                                           191       -
192       - Y                                         192       - Y
193                                                   193 
194 .. flat-table:: 4:1:0 subsampling, horizontall    194 .. flat-table:: 4:1:0 subsampling, horizontally and vertically interstitially sited
195     :header-rows: 1                               195     :header-rows: 1
196     :stub-columns: 1                              196     :stub-columns: 1
197                                                   197 
198     * -                                           198     * -
199       - 0                                         199       - 0
200       -                                           200       -
201       - 1                                         201       - 1
202       -                                           202       -
203       - 2                                         203       - 2
204       -                                           204       -
205       - 3                                         205       - 3
206     * - 0                                         206     * - 0
207       - Y                                         207       - Y
208       -                                           208       -
209       - Y                                         209       - Y
210       -                                           210       -
211       - Y                                         211       - Y
212       -                                           212       -
213       - Y                                         213       - Y
214     * -                                           214     * -
215       -                                           215       -
216       -                                           216       -
217       -                                           217       -
218       -                                           218       -
219       -                                           219       -
220       -                                           220       -
221       -                                           221       -
222     * - 1                                         222     * - 1
223       - Y                                         223       - Y
224       -                                           224       -
225       - Y                                         225       - Y
226       -                                           226       -
227       - Y                                         227       - Y
228       -                                           228       -
229       - Y                                         229       - Y
230     * -                                           230     * -
231       -                                           231       -
232       -                                           232       -
233       -                                           233       -
234       - C                                         234       - C
235       -                                           235       -
236       -                                           236       -
237       -                                           237       -
238     * - 2                                         238     * - 2
239       - Y                                         239       - Y
240       -                                           240       -
241       - Y                                         241       - Y
242       -                                           242       -
243       - Y                                         243       - Y
244       -                                           244       -
245       - Y                                         245       - Y
246     * -                                           246     * -
247       -                                           247       -
248       -                                           248       -
249       -                                           249       -
250       -                                           250       -
251       -                                           251       -
252       -                                           252       -
253       -                                           253       -
254     * - 3                                         254     * - 3
255       - Y                                         255       - Y
256       -                                           256       -
257       - Y                                         257       - Y
258       -                                           258       -
259       - Y                                         259       - Y
260       -                                           260       -
261       - Y                                         261       - Y
262                                                   262 
263                                                   263 
264 .. toctree::                                      264 .. toctree::
265     :maxdepth: 1                                  265     :maxdepth: 1
266                                                   266 
267     pixfmt-packed-yuv                             267     pixfmt-packed-yuv
268     pixfmt-yuv-planar                             268     pixfmt-yuv-planar
269     pixfmt-yuv-luma                               269     pixfmt-yuv-luma
270     pixfmt-y8i                                    270     pixfmt-y8i
271     pixfmt-y12i                                   271     pixfmt-y12i
272     pixfmt-uv8                                    272     pixfmt-uv8
273     pixfmt-m420                                   273     pixfmt-m420
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php