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. Secondary in the YUV 18 !! 18 format the U and V components usually have lower resolution than the Y 19 !! 19 component. This is an analog video compression technique taking 20 Subsampling !! 20 advantage of a property of the human visual system, being more sensitive 21 =========== !! 21 to brightness information. 22 << 23 YUV formats commonly encode images with a lowe << 24 components than for the luma component. This c << 25 advantage of the human eye being more sensitiv << 26 differences, is called chroma subsampling. << 27 << 28 While many combinations of subsampling factors << 29 direction are possible, common factors are 1 ( << 30 horizontal subsampling always larger than or e << 31 Common combinations are named as follows. << 32 << 33 - `4:4:4`: No subsampling << 34 - `4:2:2`: Horizontal subsampling by 2, no ver << 35 - `4:2:0`: Horizontal subsampling by 2, vertic << 36 - `4:1:1`: Horizontal subsampling by 4, no ver << 37 - `4:1:0`: Horizontal subsampling by 4, vertic << 38 << 39 Subsampling the chroma component effectively c << 40 located in different spatial locations: << 41 << 42 - .. _yuv-chroma-centered: << 43 << 44 The subsampled chroma value may be calculate << 45 value of two consecutive pixels. It effectiv << 46 sited between the two original pixels. This << 47 interstitially sited chroma. << 48 << 49 - .. _yuv-chroma-cosited: << 50 << 51 The other option is to subsample chroma valu << 52 the same spatial sites as the pixels. This m << 53 other chroma sample (creating aliasing artif << 54 odd number of taps. This is referred to as c << 55 << 56 The following examples show different combinat << 57 image. << 58 << 59 .. flat-table:: 4:2:2 subsampling, interstitia << 60 :header-rows: 1 << 61 :stub-columns: 1 << 62 << 63 * - << 64 - 0 << 65 - << 66 - 1 << 67 - << 68 - 2 << 69 - << 70 - 3 << 71 * - 0 << 72 - Y << 73 - C << 74 - Y << 75 - << 76 - Y << 77 - C << 78 - Y << 79 * - 1 << 80 - Y << 81 - C << 82 - Y << 83 - << 84 - Y << 85 - C << 86 - Y << 87 * - 2 << 88 - Y << 89 - C << 90 - Y << 91 - << 92 - Y << 93 - C << 94 - Y << 95 * - 3 << 96 - Y << 97 - C << 98 - Y << 99 - << 100 - Y << 101 - C << 102 - Y << 103 << 104 .. flat-table:: 4:2:2 subsampling, co-sited << 105 :header-rows: 1 << 106 :stub-columns: 1 << 107 << 108 * - << 109 - 0 << 110 - << 111 - 1 << 112 - << 113 - 2 << 114 - << 115 - 3 << 116 * - 0 << 117 - Y/C << 118 - << 119 - Y << 120 - << 121 - Y/C << 122 - << 123 - Y << 124 * - 1 << 125 - Y/C << 126 - << 127 - Y << 128 - << 129 - Y/C << 130 - << 131 - Y << 132 * - 2 << 133 - Y/C << 134 - << 135 - Y << 136 - << 137 - Y/C << 138 - << 139 - Y << 140 * - 3 << 141 - Y/C << 142 - << 143 - Y << 144 - << 145 - Y/C << 146 - << 147 - Y << 148 << 149 .. flat-table:: 4:2:0 subsampling, horizontall << 150 :header-rows: 1 << 151 :stub-columns: 1 << 152 << 153 * - << 154 - 0 << 155 - << 156 - 1 << 157 - << 158 - 2 << 159 - << 160 - 3 << 161 * - 0 << 162 - Y << 163 - C << 164 - Y << 165 - << 166 - Y << 167 - C << 168 - Y << 169 * - 1 << 170 - Y << 171 - << 172 - Y << 173 - << 174 - Y << 175 - << 176 - Y << 177 * - 2 << 178 - Y << 179 - C << 180 - Y << 181 - << 182 - Y << 183 - C << 184 - Y << 185 * - 3 << 186 - Y << 187 - << 188 - Y << 189 - << 190 - Y << 191 - << 192 - Y << 193 << 194 .. flat-table:: 4:1:0 subsampling, horizontall << 195 :header-rows: 1 << 196 :stub-columns: 1 << 197 << 198 * - << 199 - 0 << 200 - << 201 - 1 << 202 - << 203 - 2 << 204 - << 205 - 3 << 206 * - 0 << 207 - Y << 208 - << 209 - Y << 210 - << 211 - Y << 212 - << 213 - Y << 214 * - << 215 - << 216 - << 217 - << 218 - << 219 - << 220 - << 221 - << 222 * - 1 << 223 - Y << 224 - << 225 - Y << 226 - << 227 - Y << 228 - << 229 - Y << 230 * - << 231 - << 232 - << 233 - << 234 - C << 235 - << 236 - << 237 - << 238 * - 2 << 239 - Y << 240 - << 241 - Y << 242 - << 243 - Y << 244 - << 245 - Y << 246 * - << 247 - << 248 - << 249 - << 250 - << 251 - << 252 - << 253 - << 254 * - 3 << 255 - Y << 256 - << 257 - Y << 258 - << 259 - Y << 260 - << 261 - Y << 262 22 263 23 264 .. toctree:: 24 .. toctree:: 265 :maxdepth: 1 25 :maxdepth: 1 266 26 267 pixfmt-packed-yuv 27 pixfmt-packed-yuv 268 pixfmt-yuv-planar !! 28 pixfmt-grey 269 pixfmt-yuv-luma !! 29 pixfmt-y10 >> 30 pixfmt-y12 >> 31 pixfmt-y14 >> 32 pixfmt-y10b >> 33 pixfmt-y10p >> 34 pixfmt-y16 >> 35 pixfmt-y16-be 270 pixfmt-y8i 36 pixfmt-y8i 271 pixfmt-y12i 37 pixfmt-y12i 272 pixfmt-uv8 38 pixfmt-uv8 >> 39 pixfmt-yuyv >> 40 pixfmt-uyvy >> 41 pixfmt-yvyu >> 42 pixfmt-vyuy >> 43 pixfmt-y41p >> 44 pixfmt-yuv420 >> 45 pixfmt-yuv420m >> 46 pixfmt-yuv422m >> 47 pixfmt-yuv444m >> 48 pixfmt-yuv410 >> 49 pixfmt-yuv422p >> 50 pixfmt-yuv411p >> 51 pixfmt-nv12 >> 52 pixfmt-nv12m >> 53 pixfmt-nv12mt >> 54 pixfmt-nv16 >> 55 pixfmt-nv16m >> 56 pixfmt-nv24 273 pixfmt-m420 57 pixfmt-m420
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.