1.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later 2.. c:namespace:: V4L 3 4.. planar-yuv: 5 6****************** 7Planar YUV formats 8****************** 9 10Planar formats split luma and chroma data in separate memory regions. They 11exist in two variants: 12 13- Semi-planar formats use two planes. The first plane is the luma plane and 14 stores the Y components. The second plane is the chroma plane and stores the 15 Cb and Cr components interleaved. 16 17- Fully planar formats use three planes to store the Y, Cb and Cr components 18 separately. 19 20Within a plane, components are stored in pixel order, which may be linear or 21tiled. Padding may be supported at the end of the lines, and the line stride of 22the chroma planes may be constrained by the line stride of the luma plane. 23 24Some planar formats allow planes to be placed in independent memory locations. 25They are identified by an 'M' suffix in their name (such as in 26``V4L2_PIX_FMT_NV12M``). Those formats are intended to be used only in drivers 27and applications that support the multi-planar API, described in 28:ref:`planar-apis`. Unless explicitly documented as supporting non-contiguous 29planes, formats require the planes to follow each other immediately in memory. 30 31 32Semi-Planar YUV Formats 33======================= 34 35These formats are commonly referred to as NV formats (NV12, NV16, ...). They 36use two planes, and store the luma components in the first plane and the chroma 37components in the second plane. The Cb and Cr components are interleaved in the 38chroma plane, with Cb and Cr always stored in pairs. The chroma order is 39exposed as different formats. 40 41For memory contiguous formats, the number of padding pixels at the end of the 42chroma lines is identical to the padding of the luma lines. Without horizontal 43subsampling, the chroma line stride (in bytes) is thus equal to twice the luma 44line stride. With horizontal subsampling by 2, the chroma line stride is equal 45to the luma line stride. Vertical subsampling doesn't affect the line stride. 46 47For non-contiguous formats, no constraints are enforced by the format on the 48relationship between the luma and chroma line padding and stride. 49 50All components are stored with the same number of bits per component. 51 52.. raw:: latex 53 54 \footnotesize 55 56.. tabularcolumns:: |p{5.2cm}|p{1.0cm}|p{1.5cm}|p{1.9cm}|p{1.2cm}|p{1.8cm}|p{2.7cm}| 57 58.. flat-table:: Overview of Semi-Planar YUV Formats 59 :header-rows: 1 60 :stub-columns: 0 61 62 * - Identifier 63 - Code 64 - Bits per component 65 - Subsampling 66 - Chroma order [1]_ 67 - Contiguous [2]_ 68 - Tiling [3]_ 69 * - V4L2_PIX_FMT_NV12 70 - 'NV12' 71 - 8 72 - 4:2:0 73 - Cb, Cr 74 - Yes 75 - Linear 76 * - V4L2_PIX_FMT_NV21 77 - 'NV21' 78 - 8 79 - 4:2:0 80 - Cr, Cb 81 - Yes 82 - Linear 83 * - V4L2_PIX_FMT_NV12M 84 - 'NM12' 85 - 8 86 - 4:2:0 87 - Cb, Cr 88 - No 89 - Linear 90 * - V4L2_PIX_FMT_NV21M 91 - 'NM21' 92 - 8 93 - 4:2:0 94 - Cr, Cb 95 - No 96 - Linear 97 * - V4L2_PIX_FMT_NV12MT 98 - 'TM12' 99 - 8 100 - 4:2:0 101 - Cb, Cr 102 - No 103 - 64x32 tiles 104 105 Horizontal Z order 106 * - V4L2_PIX_FMT_NV12MT_16X16 107 - 'VM12' 108 - 8 109 - 4:2:2 110 - Cb, Cr 111 - No 112 - 16x16 tiles 113 * - V4L2_PIX_FMT_P010 114 - 'P010' 115 - 10 116 - 4:2:0 117 - Cb, Cr 118 - Yes 119 - Linear 120 * - V4L2_PIX_FMT_P010_4L4 121 - 'T010' 122 - 10 123 - 4:2:0 124 - Cb, Cr 125 - Yes 126 - 4x4 tiles 127 * - V4L2_PIX_FMT_P012 128 - 'P012' 129 - 12 130 - 4:2:0 131 - Cb, Cr 132 - Yes 133 - Linear 134 * - V4L2_PIX_FMT_P012M 135 - 'PM12' 136 - 12 137 - 4:2:0 138 - Cb, Cr 139 - No 140 - Linear 141 * - V4L2_PIX_FMT_NV15 142 - 'NV15' 143 - 10 144 - 4:2:0 145 - Cb, Cr 146 - Yes 147 - Linear 148 * - V4L2_PIX_FMT_NV15_4L4 149 - 'VT15' 150 - 15 151 - 4:2:0 152 - Cb, Cr 153 - Yes 154 - 4x4 tiles 155 * - V4L2_PIX_FMT_MT2110T 156 - 'MT2T' 157 - 15 158 - 4:2:0 159 - Cb, Cr 160 - No 161 - 16x32 / 16x16 tiles tiled low bits 162 * - V4L2_PIX_FMT_MT2110R 163 - 'MT2R' 164 - 15 165 - 4:2:0 166 - Cb, Cr 167 - No 168 - 16x32 / 16x16 tiles raster low bits 169 * - V4L2_PIX_FMT_NV16 170 - 'NV16' 171 - 8 172 - 4:2:2 173 - Cb, Cr 174 - Yes 175 - Linear 176 * - V4L2_PIX_FMT_NV61 177 - 'NV61' 178 - 8 179 - 4:2:2 180 - Cr, Cb 181 - Yes 182 - Linear 183 * - V4L2_PIX_FMT_NV16M 184 - 'NM16' 185 - 8 186 - 4:2:2 187 - Cb, Cr 188 - No 189 - Linear 190 * - V4L2_PIX_FMT_NV61M 191 - 'NM61' 192 - 8 193 - 4:2:2 194 - Cr, Cb 195 - No 196 - Linear 197 * - V4L2_PIX_FMT_NV20 198 - 'NV20' 199 - 10 200 - 4:2:2 201 - Cb, Cr 202 - Yes 203 - Linear 204 * - V4L2_PIX_FMT_NV24 205 - 'NV24' 206 - 8 207 - 4:4:4 208 - Cb, Cr 209 - Yes 210 - Linear 211 * - V4L2_PIX_FMT_NV42 212 - 'NV42' 213 - 8 214 - 4:4:4 215 - Cr, Cb 216 - Yes 217 - Linear 218 219.. raw:: latex 220 221 \normalsize 222 223.. [1] Order of chroma samples in the second plane 224.. [2] Indicates if planes have to be contiguous in memory or can be 225 disjoint 226.. [3] Macroblock size in pixels 227 228 229**Color Sample Location:** 230Chroma samples are :ref:`interstitially sited<yuv-chroma-centered>` 231horizontally. 232 233 234.. _V4L2-PIX-FMT-NV12: 235.. _V4L2-PIX-FMT-NV21: 236.. _V4L2-PIX-FMT-NV12M: 237.. _V4L2-PIX-FMT-NV21M: 238.. _V4L2-PIX-FMT-P010: 239 240NV12, NV21, NV12M and NV21M 241--------------------------- 242 243Semi-planar YUV 4:2:0 formats. The chroma plane is subsampled by 2 in each 244direction. Chroma lines contain half the number of pixels and the same number 245of bytes as luma lines, and the chroma plane contains half the number of lines 246of the luma plane. 247 248.. flat-table:: Sample 4x4 NV12 Image 249 :header-rows: 0 250 :stub-columns: 0 251 252 * - start + 0: 253 - Y'\ :sub:`00` 254 - Y'\ :sub:`01` 255 - Y'\ :sub:`02` 256 - Y'\ :sub:`03` 257 * - start + 4: 258 - Y'\ :sub:`10` 259 - Y'\ :sub:`11` 260 - Y'\ :sub:`12` 261 - Y'\ :sub:`13` 262 * - start + 8: 263 - Y'\ :sub:`20` 264 - Y'\ :sub:`21` 265 - Y'\ :sub:`22` 266 - Y'\ :sub:`23` 267 * - start + 12: 268 - Y'\ :sub:`30` 269 - Y'\ :sub:`31` 270 - Y'\ :sub:`32` 271 - Y'\ :sub:`33` 272 * - start + 16: 273 - Cb\ :sub:`00` 274 - Cr\ :sub:`00` 275 - Cb\ :sub:`01` 276 - Cr\ :sub:`01` 277 * - start + 20: 278 - Cb\ :sub:`10` 279 - Cr\ :sub:`10` 280 - Cb\ :sub:`11` 281 - Cr\ :sub:`11` 282 283.. flat-table:: Sample 4x4 NV12M Image 284 :header-rows: 0 285 :stub-columns: 0 286 287 * - start0 + 0: 288 - Y'\ :sub:`00` 289 - Y'\ :sub:`01` 290 - Y'\ :sub:`02` 291 - Y'\ :sub:`03` 292 * - start0 + 4: 293 - Y'\ :sub:`10` 294 - Y'\ :sub:`11` 295 - Y'\ :sub:`12` 296 - Y'\ :sub:`13` 297 * - start0 + 8: 298 - Y'\ :sub:`20` 299 - Y'\ :sub:`21` 300 - Y'\ :sub:`22` 301 - Y'\ :sub:`23` 302 * - start0 + 12: 303 - Y'\ :sub:`30` 304 - Y'\ :sub:`31` 305 - Y'\ :sub:`32` 306 - Y'\ :sub:`33` 307 * - 308 * - start1 + 0: 309 - Cb\ :sub:`00` 310 - Cr\ :sub:`00` 311 - Cb\ :sub:`01` 312 - Cr\ :sub:`01` 313 * - start1 + 4: 314 - Cb\ :sub:`10` 315 - Cr\ :sub:`10` 316 - Cb\ :sub:`11` 317 - Cr\ :sub:`11` 318 319 320.. _V4L2-PIX-FMT-NV15: 321 322NV15 323---- 324 325Semi-planar 10-bit YUV 4:2:0 format similar to NV12, using 10-bit components 326with no padding between each component. A group of 4 components are stored over 3275 bytes in little endian order. 328 329.. flat-table:: Sample 4x4 NV15 Image (1 byte per cell) 330 :header-rows: 0 331 :stub-columns: 0 332 333 * - start + 0: 334 - Y'\ :sub:`00[7:0]` 335 - Y'\ :sub:`01[5:0]`\ Y'\ :sub:`00[9:8]` 336 - Y'\ :sub:`02[3:0]`\ Y'\ :sub:`01[9:6]` 337 - Y'\ :sub:`03[1:0]`\ Y'\ :sub:`02[9:4]` 338 - Y'\ :sub:`03[9:2]` 339 * - start + 5: 340 - Y'\ :sub:`10[7:0]` 341 - Y'\ :sub:`11[5:0]`\ Y'\ :sub:`10[9:8]` 342 - Y'\ :sub:`12[3:0]`\ Y'\ :sub:`11[9:6]` 343 - Y'\ :sub:`13[1:0]`\ Y'\ :sub:`12[9:4]` 344 - Y'\ :sub:`13[9:2]` 345 * - start + 10: 346 - Y'\ :sub:`20[7:0]` 347 - Y'\ :sub:`21[5:0]`\ Y'\ :sub:`20[9:8]` 348 - Y'\ :sub:`22[3:0]`\ Y'\ :sub:`21[9:6]` 349 - Y'\ :sub:`23[1:0]`\ Y'\ :sub:`22[9:4]` 350 - Y'\ :sub:`23[9:2]` 351 * - start + 15: 352 - Y'\ :sub:`30[7:0]` 353 - Y'\ :sub:`31[5:0]`\ Y'\ :sub:`30[9:8]` 354 - Y'\ :sub:`32[3:0]`\ Y'\ :sub:`31[9:6]` 355 - Y'\ :sub:`33[1:0]`\ Y'\ :sub:`32[9:4]` 356 - Y'\ :sub:`33[9:2]` 357 * - start + 20: 358 - Cb\ :sub:`00[7:0]` 359 - Cr\ :sub:`00[5:0]`\ Cb\ :sub:`00[9:8]` 360 - Cb\ :sub:`01[3:0]`\ Cr\ :sub:`00[9:6]` 361 - Cr\ :sub:`01[1:0]`\ Cb\ :sub:`01[9:4]` 362 - Cr\ :sub:`01[9:2]` 363 * - start + 25: 364 - Cb\ :sub:`10[7:0]` 365 - Cr\ :sub:`10[5:0]`\ Cb\ :sub:`10[9:8]` 366 - Cb\ :sub:`11[3:0]`\ Cr\ :sub:`10[9:6]` 367 - Cr\ :sub:`11[1:0]`\ Cb\ :sub:`11[9:4]` 368 - Cr\ :sub:`11[9:2]` 369 370 371.. _V4L2-PIX-FMT-NV12MT: 372.. _V4L2-PIX-FMT-NV12MT-16X16: 373.. _V4L2-PIX-FMT-NV12-4L4: 374.. _V4L2-PIX-FMT-NV12-16L16: 375.. _V4L2-PIX-FMT-NV12-32L32: 376.. _V4L2-PIX-FMT-NV12M-8L128: 377.. _V4L2-PIX-FMT-NV12-8L128: 378.. _V4L2-PIX-FMT-MM21: 379 380Tiled NV12 381---------- 382 383Semi-planar YUV 4:2:0 formats, using macroblock tiling. The chroma plane is 384subsampled by 2 in each direction. Chroma lines contain half the number of 385pixels and the same number of bytes as luma lines, and the chroma plane 386contains half the number of lines of the luma plane. Each tile follows the 387previous one linearly in memory (from left to right, top to bottom). 388 389``V4L2_PIX_FMT_NV12MT_16X16`` is similar to ``V4L2_PIX_FMT_NV12M`` but stores 390pixels in 2D 16x16 tiles, and stores tiles linearly in memory. 391The line stride and image height must be aligned to a multiple of 16. 392The layouts of the luma and chroma planes are identical. 393 394``V4L2_PIX_FMT_NV12MT`` is similar to ``V4L2_PIX_FMT_NV12M`` but stores 395pixels in 2D 64x32 tiles, and stores 2x2 groups of tiles in 396Z-order in memory, alternating Z and mirrored Z shapes horizontally. 397The line stride must be a multiple of 128 pixels to ensure an 398integer number of Z shapes. The image height must be a multiple of 32 pixels. 399If the vertical resolution is an odd number of tiles, the last row of 400tiles is stored in linear order. The layouts of the luma and chroma 401planes are identical. 402 403.. _nv12mt: 404 405.. kernel-figure:: nv12mt.svg 406 :alt: nv12mt.svg 407 :align: center 408 409 V4L2_PIX_FMT_NV12MT macroblock Z shape memory layout 410 411.. _nv12mt_ex: 412 413.. kernel-figure:: nv12mt_example.svg 414 :alt: nv12mt_example.svg 415 :align: center 416 417 Example V4L2_PIX_FMT_NV12MT memory layout of tiles 418 419``V4L2_PIX_FMT_NV12_4L4`` stores pixels in 4x4 tiles, and stores 420tiles linearly in memory. The line stride and image height must be 421aligned to a multiple of 4. The layouts of the luma and chroma planes are 422identical. 423 424``V4L2_PIX_FMT_NV12_16L16`` stores pixels in 16x16 tiles, and stores 425tiles linearly in memory. The line stride and image height must be 426aligned to a multiple of 16. The layouts of the luma and chroma planes are 427identical. 428 429``V4L2_PIX_FMT_NV12_32L32`` stores pixels in 32x32 tiles, and stores 430tiles linearly in memory. The line stride and image height must be 431aligned to a multiple of 32. The layouts of the luma and chroma planes are 432identical. 433 434``V4L2_PIX_FMT_NV12M_8L128`` is similar to ``V4L2_PIX_FMT_NV12M`` but stores 435pixels in 2D 8x128 tiles, and stores tiles linearly in memory. 436The image height must be aligned to a multiple of 128. 437The layouts of the luma and chroma planes are identical. 438 439``V4L2_PIX_FMT_NV12_8L128`` is similar to ``V4L2_PIX_FMT_NV12M_8L128`` but stores 440two planes in one memory. 441 442``V4L2_PIX_FMT_MM21`` store luma pixel in 16x32 tiles, and chroma pixels 443in 16x16 tiles. The line stride must be aligned to a multiple of 16 and the 444image height must be aligned to a multiple of 32. The number of luma and chroma 445tiles are identical, even though the tile size differ. The image is formed of 446two non-contiguous planes. 447 448 449.. _V4L2-PIX-FMT-NV15-4L4: 450.. _V4L2-PIX-FMT-NV12M-10BE-8L128: 451.. _V4L2-PIX-FMT-NV12-10BE-8L128: 452.. _V4L2-PIX-FMT-MT2110T: 453.. _V4L2-PIX-FMT-MT2110R: 454 455Tiled NV15 456---------- 457 458``V4L2_PIX_FMT_NV15_4L4`` Semi-planar 10-bit YUV 4:2:0 formats, using 4x4 tiling. 459All components are packed without any padding between each other. 460As a side-effect, each group of 4 components are stored over 5 bytes 461(YYYY or UVUV = 4 * 10 bits = 40 bits = 5 bytes). 462 463``V4L2_PIX_FMT_NV12M_10BE_8L128`` is similar to ``V4L2_PIX_FMT_NV12M`` but stores 46410 bits pixels in 2D 8x128 tiles, and stores tiles linearly in memory. 465the data is arranged in big endian order. 466The image height must be aligned to a multiple of 128. 467The layouts of the luma and chroma planes are identical. 468Note the tile size is 8bytes multiplied by 128 bytes, 469it means that the low bits and high bits of one pixel may be in different tiles. 470The 10 bit pixels are packed, so 5 bytes contain 4 10-bit pixels layout like 471this (for luma): 472byte 0: Y0(bits 9-2) 473byte 1: Y0(bits 1-0) Y1(bits 9-4) 474byte 2: Y1(bits 3-0) Y2(bits 9-6) 475byte 3: Y2(bits 5-0) Y3(bits 9-8) 476byte 4: Y3(bits 7-0) 477 478``V4L2_PIX_FMT_NV12_10BE_8L128`` is similar to ``V4L2_PIX_FMT_NV12M_10BE_8L128`` but stores 479two planes in one memory. 480 481``V4L2_PIX_FMT_MT2110T`` is one of Mediatek packed 10bit YUV 4:2:0 formats. 482It is fully packed 10bit 4:2:0 format like NV15 (15 bits per pixel), except 483that the lower two bits data is stored in separate partitions. The format is 484composed of 16x32 luma tiles, and 16x16 chroma tiles. Each tiles is 640 bytes 485long, divided into 8 partitions of 80 bytes. The first 16 bytes of the 486partition represent the 2 least significant bits of pixel data. The remaining 48764 bytes represent the 8 most significant bits of pixel data. 488 489.. kernel-figure:: mt2110t.svg 490 :alt: mt2110t.svg 491 :align: center 492 493 Layout of MT2110T Chroma Tile 494 495Filtering out the upper part of each partitions results in a valid 496``V4L2_PIX_FMT_MM21`` frame. A partition is a sub-tile of size 16 x 4. The 497lower two bits is said to be tiled since each bytes contains the lower two 498bits of the column of for pixel matching the same index. The chroma tiles 499only have 4 partitions. 500 501.. flat-table:: MT2110T LSB bits layout 502 :header-rows: 1 503 :stub-columns: 1 504 505 * - 506 - start + 0: 507 - start + 1: 508 - . . . 509 - start\ +\ 15: 510 * - Bits 1:0 511 - Y'\ :sub:`0:0` 512 - Y'\ :sub:`0:1` 513 - . . . 514 - Y'\ :sub:`0:15` 515 * - Bit 3:2 516 - Y'\ :sub:`1:0` 517 - Y'\ :sub:`1:1` 518 - . . . 519 - Y'\ :sub:`1:15` 520 * - Bits 5:4 521 - Y'\ :sub:`2:0` 522 - Y'\ :sub:`2:1` 523 - . . . 524 - Y'\ :sub:`2:15` 525 * - Bits 7:6 526 - Y'\ :sub:`3:0` 527 - Y'\ :sub:`3:1` 528 - . . . 529 - Y'\ :sub:`3:15` 530 531``V4L2_PIX_FMT_MT2110R`` is identical to ``V4L2_PIX_FMT_MT2110T`` except that 532the least significant two bits layout is in raster order. This means the first byte 533contains 4 pixels of the first row, with 4 bytes per line. 534 535.. flat-table:: MT2110R LSB bits layout 536 :header-rows: 2 537 :stub-columns: 1 538 539 * - 540 - :cspan:`3` Byte 0 541 - ... 542 - :cspan:`3` Byte 3 543 * - 544 - 7:6 545 - 5:4 546 - 3:2 547 - 1:0 548 - ... 549 - 7:6 550 - 5:4 551 - 3:2 552 - 1:0 553 * - start + 0: 554 - Y'\ :sub:`0:3` 555 - Y'\ :sub:`0:2` 556 - Y'\ :sub:`0:1` 557 - Y'\ :sub:`0:0` 558 - ... 559 - Y'\ :sub:`0:15` 560 - Y'\ :sub:`0:14` 561 - Y'\ :sub:`0:13` 562 - Y'\ :sub:`0:12` 563 * - start + 4: 564 - Y'\ :sub:`1:3` 565 - Y'\ :sub:`1:2` 566 - Y'\ :sub:`1:1` 567 - Y'\ :sub:`1:0` 568 - ... 569 - Y'\ :sub:`1:15` 570 - Y'\ :sub:`1:14` 571 - Y'\ :sub:`1:13` 572 - Y'\ :sub:`1:12` 573 * - start + 8: 574 - Y'\ :sub:`2:3` 575 - Y'\ :sub:`2:2` 576 - Y'\ :sub:`2:1` 577 - Y'\ :sub:`2:0` 578 - ... 579 - Y'\ :sub:`2:15` 580 - Y'\ :sub:`2:14` 581 - Y'\ :sub:`2:13` 582 - Y'\ :sub:`2:12` 583 * - start\ +\ 12: 584 - Y'\ :sub:`3:3` 585 - Y'\ :sub:`3:2` 586 - Y'\ :sub:`3:1` 587 - Y'\ :sub:`3:0` 588 - ... 589 - Y'\ :sub:`3:15` 590 - Y'\ :sub:`3:14` 591 - Y'\ :sub:`3:13` 592 - Y'\ :sub:`3:12` 593 594 595.. _V4L2-PIX-FMT-NV16: 596.. _V4L2-PIX-FMT-NV61: 597.. _V4L2-PIX-FMT-NV16M: 598.. _V4L2-PIX-FMT-NV61M: 599 600NV16, NV61, NV16M and NV61M 601--------------------------- 602 603Semi-planar YUV 4:2:2 formats. The chroma plane is subsampled by 2 in the 604horizontal direction. Chroma lines contain half the number of pixels and the 605same number of bytes as luma lines, and the chroma plane contains the same 606number of lines as the luma plane. 607 608.. flat-table:: Sample 4x4 NV16 Image 609 :header-rows: 0 610 :stub-columns: 0 611 612 * - start + 0: 613 - Y'\ :sub:`00` 614 - Y'\ :sub:`01` 615 - Y'\ :sub:`02` 616 - Y'\ :sub:`03` 617 * - start + 4: 618 - Y'\ :sub:`10` 619 - Y'\ :sub:`11` 620 - Y'\ :sub:`12` 621 - Y'\ :sub:`13` 622 * - start + 8: 623 - Y'\ :sub:`20` 624 - Y'\ :sub:`21` 625 - Y'\ :sub:`22` 626 - Y'\ :sub:`23` 627 * - start + 12: 628 - Y'\ :sub:`30` 629 - Y'\ :sub:`31` 630 - Y'\ :sub:`32` 631 - Y'\ :sub:`33` 632 * - start + 16: 633 - Cb\ :sub:`00` 634 - Cr\ :sub:`00` 635 - Cb\ :sub:`01` 636 - Cr\ :sub:`01` 637 * - start + 20: 638 - Cb\ :sub:`10` 639 - Cr\ :sub:`10` 640 - Cb\ :sub:`11` 641 - Cr\ :sub:`11` 642 * - start + 24: 643 - Cb\ :sub:`20` 644 - Cr\ :sub:`20` 645 - Cb\ :sub:`21` 646 - Cr\ :sub:`21` 647 * - start + 28: 648 - Cb\ :sub:`30` 649 - Cr\ :sub:`30` 650 - Cb\ :sub:`31` 651 - Cr\ :sub:`31` 652 653.. flat-table:: Sample 4x4 NV16M Image 654 :header-rows: 0 655 :stub-columns: 0 656 657 * - start0 + 0: 658 - Y'\ :sub:`00` 659 - Y'\ :sub:`01` 660 - Y'\ :sub:`02` 661 - Y'\ :sub:`03` 662 * - start0 + 4: 663 - Y'\ :sub:`10` 664 - Y'\ :sub:`11` 665 - Y'\ :sub:`12` 666 - Y'\ :sub:`13` 667 * - start0 + 8: 668 - Y'\ :sub:`20` 669 - Y'\ :sub:`21` 670 - Y'\ :sub:`22` 671 - Y'\ :sub:`23` 672 * - start0 + 12: 673 - Y'\ :sub:`30` 674 - Y'\ :sub:`31` 675 - Y'\ :sub:`32` 676 - Y'\ :sub:`33` 677 * - 678 * - start1 + 0: 679 - Cb\ :sub:`00` 680 - Cr\ :sub:`00` 681 - Cb\ :sub:`02` 682 - Cr\ :sub:`02` 683 * - start1 + 4: 684 - Cb\ :sub:`10` 685 - Cr\ :sub:`10` 686 - Cb\ :sub:`12` 687 - Cr\ :sub:`12` 688 * - start1 + 8: 689 - Cb\ :sub:`20` 690 - Cr\ :sub:`20` 691 - Cb\ :sub:`22` 692 - Cr\ :sub:`22` 693 * - start1 + 12: 694 - Cb\ :sub:`30` 695 - Cr\ :sub:`30` 696 - Cb\ :sub:`32` 697 - Cr\ :sub:`32` 698 699 700.. _V4L2-PIX-FMT-NV20: 701 702NV20 703---- 704 705Semi-planar 10-bit YUV 4:2:2 format similar to NV16, using 10-bit components 706with no padding between each component. A group of 4 components are stored over 7075 bytes in little endian order. 708 709.. flat-table:: Sample 4x4 NV20 Image (1 byte per cell) 710 :header-rows: 0 711 :stub-columns: 0 712 713 * - start + 0: 714 - Y'\ :sub:`00[7:0]` 715 - Y'\ :sub:`01[5:0]`\ Y'\ :sub:`00[9:8]` 716 - Y'\ :sub:`02[3:0]`\ Y'\ :sub:`01[9:6]` 717 - Y'\ :sub:`03[1:0]`\ Y'\ :sub:`02[9:4]` 718 - Y'\ :sub:`03[9:2]` 719 * - start + 5: 720 - Y'\ :sub:`10[7:0]` 721 - Y'\ :sub:`11[5:0]`\ Y'\ :sub:`10[9:8]` 722 - Y'\ :sub:`12[3:0]`\ Y'\ :sub:`11[9:6]` 723 - Y'\ :sub:`13[1:0]`\ Y'\ :sub:`12[9:4]` 724 - Y'\ :sub:`13[9:2]` 725 * - start + 10: 726 - Y'\ :sub:`20[7:0]` 727 - Y'\ :sub:`21[5:0]`\ Y'\ :sub:`20[9:8]` 728 - Y'\ :sub:`22[3:0]`\ Y'\ :sub:`21[9:6]` 729 - Y'\ :sub:`23[1:0]`\ Y'\ :sub:`22[9:4]` 730 - Y'\ :sub:`23[9:2]` 731 * - start + 15: 732 - Y'\ :sub:`30[7:0]` 733 - Y'\ :sub:`31[5:0]`\ Y'\ :sub:`30[9:8]` 734 - Y'\ :sub:`32[3:0]`\ Y'\ :sub:`31[9:6]` 735 - Y'\ :sub:`33[1:0]`\ Y'\ :sub:`32[9:4]` 736 - Y'\ :sub:`33[9:2]` 737 * - start + 20: 738 - Cb\ :sub:`00[7:0]` 739 - Cr\ :sub:`00[5:0]`\ Cb\ :sub:`00[9:8]` 740 - Cb\ :sub:`01[3:0]`\ Cr\ :sub:`00[9:6]` 741 - Cr\ :sub:`01[1:0]`\ Cb\ :sub:`01[9:4]` 742 - Cr\ :sub:`01[9:2]` 743 * - start + 25: 744 - Cb\ :sub:`10[7:0]` 745 - Cr\ :sub:`10[5:0]`\ Cb\ :sub:`10[9:8]` 746 - Cb\ :sub:`11[3:0]`\ Cr\ :sub:`10[9:6]` 747 - Cr\ :sub:`11[1:0]`\ Cb\ :sub:`11[9:4]` 748 - Cr\ :sub:`11[9:2]` 749 * - start + 30: 750 - Cb\ :sub:`20[7:0]` 751 - Cr\ :sub:`20[5:0]`\ Cb\ :sub:`20[9:8]` 752 - Cb\ :sub:`21[3:0]`\ Cr\ :sub:`20[9:6]` 753 - Cr\ :sub:`21[1:0]`\ Cb\ :sub:`21[9:4]` 754 - Cr\ :sub:`21[9:2]` 755 * - start + 35: 756 - Cb\ :sub:`30[7:0]` 757 - Cr\ :sub:`30[5:0]`\ Cb\ :sub:`30[9:8]` 758 - Cb\ :sub:`31[3:0]`\ Cr\ :sub:`30[9:6]` 759 - Cr\ :sub:`31[1:0]`\ Cb\ :sub:`31[9:4]` 760 - Cr\ :sub:`31[9:2]` 761 762 763.. _V4L2-PIX-FMT-NV24: 764.. _V4L2-PIX-FMT-NV42: 765 766NV24 and NV42 767------------- 768 769Semi-planar YUV 4:4:4 formats. The chroma plane is not subsampled. 770Chroma lines contain the same number of pixels and twice the 771number of bytes as luma lines, and the chroma plane contains the same 772number of lines as the luma plane. 773 774.. flat-table:: Sample 4x4 NV24 Image 775 :header-rows: 0 776 :stub-columns: 0 777 778 * - start + 0: 779 - Y'\ :sub:`00` 780 - Y'\ :sub:`01` 781 - Y'\ :sub:`02` 782 - Y'\ :sub:`03` 783 * - start + 4: 784 - Y'\ :sub:`10` 785 - Y'\ :sub:`11` 786 - Y'\ :sub:`12` 787 - Y'\ :sub:`13` 788 * - start + 8: 789 - Y'\ :sub:`20` 790 - Y'\ :sub:`21` 791 - Y'\ :sub:`22` 792 - Y'\ :sub:`23` 793 * - start + 12: 794 - Y'\ :sub:`30` 795 - Y'\ :sub:`31` 796 - Y'\ :sub:`32` 797 - Y'\ :sub:`33` 798 * - start + 16: 799 - Cb\ :sub:`00` 800 - Cr\ :sub:`00` 801 - Cb\ :sub:`01` 802 - Cr\ :sub:`01` 803 - Cb\ :sub:`02` 804 - Cr\ :sub:`02` 805 - Cb\ :sub:`03` 806 - Cr\ :sub:`03` 807 * - start + 24: 808 - Cb\ :sub:`10` 809 - Cr\ :sub:`10` 810 - Cb\ :sub:`11` 811 - Cr\ :sub:`11` 812 - Cb\ :sub:`12` 813 - Cr\ :sub:`12` 814 - Cb\ :sub:`13` 815 - Cr\ :sub:`13` 816 * - start + 32: 817 - Cb\ :sub:`20` 818 - Cr\ :sub:`20` 819 - Cb\ :sub:`21` 820 - Cr\ :sub:`21` 821 - Cb\ :sub:`22` 822 - Cr\ :sub:`22` 823 - Cb\ :sub:`23` 824 - Cr\ :sub:`23` 825 * - start + 40: 826 - Cb\ :sub:`30` 827 - Cr\ :sub:`30` 828 - Cb\ :sub:`31` 829 - Cr\ :sub:`31` 830 - Cb\ :sub:`32` 831 - Cr\ :sub:`32` 832 - Cb\ :sub:`33` 833 - Cr\ :sub:`33` 834 835.. _V4L2_PIX_FMT_P010: 836.. _V4L2-PIX-FMT-P010-4L4: 837 838P010 and tiled P010 839------------------- 840 841P010 is like NV12 with 10 bits per component, expanded to 16 bits. 842Data in the 10 high bits, zeros in the 6 low bits, arranged in little endian order. 843 844.. flat-table:: Sample 4x4 P010 Image 845 :header-rows: 0 846 :stub-columns: 0 847 848 * - start + 0: 849 - Y'\ :sub:`00` 850 - Y'\ :sub:`01` 851 - Y'\ :sub:`02` 852 - Y'\ :sub:`03` 853 * - start + 8: 854 - Y'\ :sub:`10` 855 - Y'\ :sub:`11` 856 - Y'\ :sub:`12` 857 - Y'\ :sub:`13` 858 * - start + 16: 859 - Y'\ :sub:`20` 860 - Y'\ :sub:`21` 861 - Y'\ :sub:`22` 862 - Y'\ :sub:`23` 863 * - start + 24: 864 - Y'\ :sub:`30` 865 - Y'\ :sub:`31` 866 - Y'\ :sub:`32` 867 - Y'\ :sub:`33` 868 * - start + 32: 869 - Cb\ :sub:`00` 870 - Cr\ :sub:`00` 871 - Cb\ :sub:`01` 872 - Cr\ :sub:`01` 873 * - start + 40: 874 - Cb\ :sub:`10` 875 - Cr\ :sub:`10` 876 - Cb\ :sub:`11` 877 - Cr\ :sub:`11` 878 879.. _V4L2-PIX-FMT-P012: 880.. _V4L2-PIX-FMT-P012M: 881 882P012 and P012M 883-------------- 884 885P012 is like NV12 with 12 bits per component, expanded to 16 bits. 886Data in the 12 high bits, zeros in the 4 low bits, arranged in little endian order. 887 888.. flat-table:: Sample 4x4 P012 Image 889 :header-rows: 0 890 :stub-columns: 0 891 892 * - start + 0: 893 - Y'\ :sub:`00` 894 - Y'\ :sub:`01` 895 - Y'\ :sub:`02` 896 - Y'\ :sub:`03` 897 * - start + 8: 898 - Y'\ :sub:`10` 899 - Y'\ :sub:`11` 900 - Y'\ :sub:`12` 901 - Y'\ :sub:`13` 902 * - start + 16: 903 - Y'\ :sub:`20` 904 - Y'\ :sub:`21` 905 - Y'\ :sub:`22` 906 - Y'\ :sub:`23` 907 * - start + 24: 908 - Y'\ :sub:`30` 909 - Y'\ :sub:`31` 910 - Y'\ :sub:`32` 911 - Y'\ :sub:`33` 912 * - start + 32: 913 - Cb\ :sub:`00` 914 - Cr\ :sub:`00` 915 - Cb\ :sub:`01` 916 - Cr\ :sub:`01` 917 * - start + 40: 918 - Cb\ :sub:`10` 919 - Cr\ :sub:`10` 920 - Cb\ :sub:`11` 921 - Cr\ :sub:`11` 922 923.. flat-table:: Sample 4x4 P012M Image 924 :header-rows: 0 925 :stub-columns: 0 926 927 * - start0 + 0: 928 - Y'\ :sub:`00` 929 - Y'\ :sub:`01` 930 - Y'\ :sub:`02` 931 - Y'\ :sub:`03` 932 * - start0 + 8: 933 - Y'\ :sub:`10` 934 - Y'\ :sub:`11` 935 - Y'\ :sub:`12` 936 - Y'\ :sub:`13` 937 * - start0 + 16: 938 - Y'\ :sub:`20` 939 - Y'\ :sub:`21` 940 - Y'\ :sub:`22` 941 - Y'\ :sub:`23` 942 * - start0 + 24: 943 - Y'\ :sub:`30` 944 - Y'\ :sub:`31` 945 - Y'\ :sub:`32` 946 - Y'\ :sub:`33` 947 * - 948 * - start1 + 0: 949 - Cb\ :sub:`00` 950 - Cr\ :sub:`00` 951 - Cb\ :sub:`01` 952 - Cr\ :sub:`01` 953 * - start1 + 8: 954 - Cb\ :sub:`10` 955 - Cr\ :sub:`10` 956 - Cb\ :sub:`11` 957 - Cr\ :sub:`11` 958 959 960Fully Planar YUV Formats 961======================== 962 963These formats store the Y, Cb and Cr components in three separate planes. The 964luma plane comes first, and the order of the two chroma planes varies between 965formats. The two chroma planes always use the same subsampling. 966 967For memory contiguous formats, the number of padding pixels at the end of the 968chroma lines is identical to the padding of the luma lines. The chroma line 969stride (in bytes) is thus equal to the luma line stride divided by the 970horizontal subsampling factor. Vertical subsampling doesn't affect the line 971stride. 972 973For non-contiguous formats, no constraints are enforced by the format on the 974relationship between the luma and chroma line padding and stride. 975 976All components are stored with the same number of bits per component. 977 978``V4L2_PIX_FMT_P010_4L4`` stores pixels in 4x4 tiles, and stores tiles linearly 979in memory. The line stride must be aligned to multiple of 8 and image height to 980a multiple of 4. The layouts of the luma and chroma planes are identical. 981 982.. raw:: latex 983 984 \small 985 986.. tabularcolumns:: |p{5.0cm}|p{1.1cm}|p{1.5cm}|p{2.2cm}|p{1.2cm}|p{3.7cm}| 987 988.. flat-table:: Overview of Fully Planar YUV Formats 989 :header-rows: 1 990 :stub-columns: 0 991 992 * - Identifier 993 - Code 994 - Bits per component 995 - Subsampling 996 - Planes order [4]_ 997 - Contiguous [5]_ 998 999 * - V4L2_PIX_FMT_YUV410 1000 - 'YUV9' 1001 - 8 1002 - 4:1:0 1003 - Y, Cb, Cr 1004 - Yes 1005 * - V4L2_PIX_FMT_YVU410 1006 - 'YVU9' 1007 - 8 1008 - 4:1:0 1009 - Y, Cr, Cb 1010 - Yes 1011 * - V4L2_PIX_FMT_YUV411P 1012 - '411P' 1013 - 8 1014 - 4:1:1 1015 - Y, Cb, Cr 1016 - Yes 1017 * - V4L2_PIX_FMT_YUV420M 1018 - 'YM12' 1019 - 8 1020 - 4:2:0 1021 - Y, Cb, Cr 1022 - No 1023 * - V4L2_PIX_FMT_YVU420M 1024 - 'YM21' 1025 - 8 1026 - 4:2:0 1027 - Y, Cr, Cb 1028 - No 1029 * - V4L2_PIX_FMT_YUV420 1030 - 'YU12' 1031 - 8 1032 - 4:2:0 1033 - Y, Cb, Cr 1034 - Yes 1035 * - V4L2_PIX_FMT_YVU420 1036 - 'YV12' 1037 - 8 1038 - 4:2:0 1039 - Y, Cr, Cb 1040 - Yes 1041 * - V4L2_PIX_FMT_YUV422P 1042 - '422P' 1043 - 8 1044 - 4:2:2 1045 - Y, Cb, Cr 1046 - Yes 1047 * - V4L2_PIX_FMT_YUV422M 1048 - 'YM16' 1049 - 8 1050 - 4:2:2 1051 - Y, Cb, Cr 1052 - No 1053 * - V4L2_PIX_FMT_YVU422M 1054 - 'YM61' 1055 - 8 1056 - 4:2:2 1057 - Y, Cr, Cb 1058 - No 1059 * - V4L2_PIX_FMT_YUV444M 1060 - 'YM24' 1061 - 8 1062 - 4:4:4 1063 - Y, Cb, Cr 1064 - No 1065 * - V4L2_PIX_FMT_YVU444M 1066 - 'YM42' 1067 - 8 1068 - 4:4:4 1069 - Y, Cr, Cb 1070 - No 1071 1072.. raw:: latex 1073 1074 \normalsize 1075 1076.. [4] Order of luma and chroma planes 1077.. [5] Indicates if planes have to be contiguous in memory or can be 1078 disjoint 1079 1080 1081**Color Sample Location:** 1082Chroma samples are :ref:`interstitially sited<yuv-chroma-centered>` 1083horizontally. 1084 1085.. _V4L2-PIX-FMT-YUV410: 1086.. _V4L2-PIX-FMT-YVU410: 1087 1088YUV410 and YVU410 1089----------------- 1090 1091Planar YUV 4:1:0 formats. The chroma planes are subsampled by 4 in each 1092direction. Chroma lines contain a quarter of the number of pixels and bytes of 1093the luma lines, and the chroma planes contain a quarter of the number of lines 1094of the luma plane. 1095 1096.. flat-table:: Sample 4x4 YUV410 Image 1097 :header-rows: 0 1098 :stub-columns: 0 1099 1100 * - start + 0: 1101 - Y'\ :sub:`00` 1102 - Y'\ :sub:`01` 1103 - Y'\ :sub:`02` 1104 - Y'\ :sub:`03` 1105 * - start + 4: 1106 - Y'\ :sub:`10` 1107 - Y'\ :sub:`11` 1108 - Y'\ :sub:`12` 1109 - Y'\ :sub:`13` 1110 * - start + 8: 1111 - Y'\ :sub:`20` 1112 - Y'\ :sub:`21` 1113 - Y'\ :sub:`22` 1114 - Y'\ :sub:`23` 1115 * - start + 12: 1116 - Y'\ :sub:`30` 1117 - Y'\ :sub:`31` 1118 - Y'\ :sub:`32` 1119 - Y'\ :sub:`33` 1120 * - start + 16: 1121 - Cr\ :sub:`00` 1122 * - start + 17: 1123 - Cb\ :sub:`00` 1124 1125 1126.. _V4L2-PIX-FMT-YUV411P: 1127 1128YUV411P 1129------- 1130 1131Planar YUV 4:1:1 formats. The chroma planes are subsampled by 4 in the 1132horizontal direction. Chroma lines contain a quarter of the number of pixels 1133and bytes of the luma lines, and the chroma planes contain the same number of 1134lines as the luma plane. 1135 1136.. flat-table:: Sample 4x4 YUV411P Image 1137 :header-rows: 0 1138 :stub-columns: 0 1139 1140 * - start + 0: 1141 - Y'\ :sub:`00` 1142 - Y'\ :sub:`01` 1143 - Y'\ :sub:`02` 1144 - Y'\ :sub:`03` 1145 * - start + 4: 1146 - Y'\ :sub:`10` 1147 - Y'\ :sub:`11` 1148 - Y'\ :sub:`12` 1149 - Y'\ :sub:`13` 1150 * - start + 8: 1151 - Y'\ :sub:`20` 1152 - Y'\ :sub:`21` 1153 - Y'\ :sub:`22` 1154 - Y'\ :sub:`23` 1155 * - start + 12: 1156 - Y'\ :sub:`30` 1157 - Y'\ :sub:`31` 1158 - Y'\ :sub:`32` 1159 - Y'\ :sub:`33` 1160 * - start + 16: 1161 - Cb\ :sub:`00` 1162 * - start + 17: 1163 - Cb\ :sub:`10` 1164 * - start + 18: 1165 - Cb\ :sub:`20` 1166 * - start + 19: 1167 - Cb\ :sub:`30` 1168 * - start + 20: 1169 - Cr\ :sub:`00` 1170 * - start + 21: 1171 - Cr\ :sub:`10` 1172 * - start + 22: 1173 - Cr\ :sub:`20` 1174 * - start + 23: 1175 - Cr\ :sub:`30` 1176 1177 1178.. _V4L2-PIX-FMT-YUV420: 1179.. _V4L2-PIX-FMT-YVU420: 1180.. _V4L2-PIX-FMT-YUV420M: 1181.. _V4L2-PIX-FMT-YVU420M: 1182 1183YUV420, YVU420, YUV420M and YVU420M 1184----------------------------------- 1185 1186Planar YUV 4:2:0 formats. The chroma planes are subsampled by 2 in each 1187direction. Chroma lines contain half of the number of pixels and bytes of the 1188luma lines, and the chroma planes contain half of the number of lines of the 1189luma plane. 1190 1191.. flat-table:: Sample 4x4 YUV420 Image 1192 :header-rows: 0 1193 :stub-columns: 0 1194 1195 * - start + 0: 1196 - Y'\ :sub:`00` 1197 - Y'\ :sub:`01` 1198 - Y'\ :sub:`02` 1199 - Y'\ :sub:`03` 1200 * - start + 4: 1201 - Y'\ :sub:`10` 1202 - Y'\ :sub:`11` 1203 - Y'\ :sub:`12` 1204 - Y'\ :sub:`13` 1205 * - start + 8: 1206 - Y'\ :sub:`20` 1207 - Y'\ :sub:`21` 1208 - Y'\ :sub:`22` 1209 - Y'\ :sub:`23` 1210 * - start + 12: 1211 - Y'\ :sub:`30` 1212 - Y'\ :sub:`31` 1213 - Y'\ :sub:`32` 1214 - Y'\ :sub:`33` 1215 * - start + 16: 1216 - Cr\ :sub:`00` 1217 - Cr\ :sub:`01` 1218 * - start + 18: 1219 - Cr\ :sub:`10` 1220 - Cr\ :sub:`11` 1221 * - start + 20: 1222 - Cb\ :sub:`00` 1223 - Cb\ :sub:`01` 1224 * - start + 22: 1225 - Cb\ :sub:`10` 1226 - Cb\ :sub:`11` 1227 1228.. flat-table:: Sample 4x4 YUV420M Image 1229 :header-rows: 0 1230 :stub-columns: 0 1231 1232 * - start0 + 0: 1233 - Y'\ :sub:`00` 1234 - Y'\ :sub:`01` 1235 - Y'\ :sub:`02` 1236 - Y'\ :sub:`03` 1237 * - start0 + 4: 1238 - Y'\ :sub:`10` 1239 - Y'\ :sub:`11` 1240 - Y'\ :sub:`12` 1241 - Y'\ :sub:`13` 1242 * - start0 + 8: 1243 - Y'\ :sub:`20` 1244 - Y'\ :sub:`21` 1245 - Y'\ :sub:`22` 1246 - Y'\ :sub:`23` 1247 * - start0 + 12: 1248 - Y'\ :sub:`30` 1249 - Y'\ :sub:`31` 1250 - Y'\ :sub:`32` 1251 - Y'\ :sub:`33` 1252 * - 1253 * - start1 + 0: 1254 - Cb\ :sub:`00` 1255 - Cb\ :sub:`01` 1256 * - start1 + 2: 1257 - Cb\ :sub:`10` 1258 - Cb\ :sub:`11` 1259 * - 1260 * - start2 + 0: 1261 - Cr\ :sub:`00` 1262 - Cr\ :sub:`01` 1263 * - start2 + 2: 1264 - Cr\ :sub:`10` 1265 - Cr\ :sub:`11` 1266 1267 1268.. _V4L2-PIX-FMT-YUV422P: 1269.. _V4L2-PIX-FMT-YUV422M: 1270.. _V4L2-PIX-FMT-YVU422M: 1271 1272YUV422P, YUV422M and YVU422M 1273---------------------------- 1274 1275Planar YUV 4:2:2 formats. The chroma planes are subsampled by 2 in the 1276horizontal direction. Chroma lines contain half of the number of pixels and 1277bytes of the luma lines, and the chroma planes contain the same number of lines 1278as the luma plane. 1279 1280.. flat-table:: Sample 4x4 YUV422P Image 1281 :header-rows: 0 1282 :stub-columns: 0 1283 1284 * - start + 0: 1285 - Y'\ :sub:`00` 1286 - Y'\ :sub:`01` 1287 - Y'\ :sub:`02` 1288 - Y'\ :sub:`03` 1289 * - start + 4: 1290 - Y'\ :sub:`10` 1291 - Y'\ :sub:`11` 1292 - Y'\ :sub:`12` 1293 - Y'\ :sub:`13` 1294 * - start + 8: 1295 - Y'\ :sub:`20` 1296 - Y'\ :sub:`21` 1297 - Y'\ :sub:`22` 1298 - Y'\ :sub:`23` 1299 * - start + 12: 1300 - Y'\ :sub:`30` 1301 - Y'\ :sub:`31` 1302 - Y'\ :sub:`32` 1303 - Y'\ :sub:`33` 1304 * - start + 16: 1305 - Cb\ :sub:`00` 1306 - Cb\ :sub:`01` 1307 * - start + 18: 1308 - Cb\ :sub:`10` 1309 - Cb\ :sub:`11` 1310 * - start + 20: 1311 - Cb\ :sub:`20` 1312 - Cb\ :sub:`21` 1313 * - start + 22: 1314 - Cb\ :sub:`30` 1315 - Cb\ :sub:`31` 1316 * - start + 24: 1317 - Cr\ :sub:`00` 1318 - Cr\ :sub:`01` 1319 * - start + 26: 1320 - Cr\ :sub:`10` 1321 - Cr\ :sub:`11` 1322 * - start + 28: 1323 - Cr\ :sub:`20` 1324 - Cr\ :sub:`21` 1325 * - start + 30: 1326 - Cr\ :sub:`30` 1327 - Cr\ :sub:`31` 1328 1329.. flat-table:: Sample 4x4 YUV422M Image 1330 :header-rows: 0 1331 :stub-columns: 0 1332 1333 * - start0 + 0: 1334 - Y'\ :sub:`00` 1335 - Y'\ :sub:`01` 1336 - Y'\ :sub:`02` 1337 - Y'\ :sub:`03` 1338 * - start0 + 4: 1339 - Y'\ :sub:`10` 1340 - Y'\ :sub:`11` 1341 - Y'\ :sub:`12` 1342 - Y'\ :sub:`13` 1343 * - start0 + 8: 1344 - Y'\ :sub:`20` 1345 - Y'\ :sub:`21` 1346 - Y'\ :sub:`22` 1347 - Y'\ :sub:`23` 1348 * - start0 + 12: 1349 - Y'\ :sub:`30` 1350 - Y'\ :sub:`31` 1351 - Y'\ :sub:`32` 1352 - Y'\ :sub:`33` 1353 * - 1354 * - start1 + 0: 1355 - Cb\ :sub:`00` 1356 - Cb\ :sub:`01` 1357 * - start1 + 2: 1358 - Cb\ :sub:`10` 1359 - Cb\ :sub:`11` 1360 * - start1 + 4: 1361 - Cb\ :sub:`20` 1362 - Cb\ :sub:`21` 1363 * - start1 + 6: 1364 - Cb\ :sub:`30` 1365 - Cb\ :sub:`31` 1366 * - 1367 * - start2 + 0: 1368 - Cr\ :sub:`00` 1369 - Cr\ :sub:`01` 1370 * - start2 + 2: 1371 - Cr\ :sub:`10` 1372 - Cr\ :sub:`11` 1373 * - start2 + 4: 1374 - Cr\ :sub:`20` 1375 - Cr\ :sub:`21` 1376 * - start2 + 6: 1377 - Cr\ :sub:`30` 1378 - Cr\ :sub:`31` 1379 1380 1381.. _V4L2-PIX-FMT-YUV444M: 1382.. _V4L2-PIX-FMT-YVU444M: 1383 1384YUV444M and YVU444M 1385------------------- 1386 1387Planar YUV 4:4:4 formats. The chroma planes are no subsampled. Chroma lines 1388contain the same number of pixels and bytes of the luma lines, and the chroma 1389planes contain the same number of lines as the luma plane. 1390 1391.. flat-table:: Sample 4x4 YUV444M Image 1392 :header-rows: 0 1393 :stub-columns: 0 1394 1395 * - start0 + 0: 1396 - Y'\ :sub:`00` 1397 - Y'\ :sub:`01` 1398 - Y'\ :sub:`02` 1399 - Y'\ :sub:`03` 1400 * - start0 + 4: 1401 - Y'\ :sub:`10` 1402 - Y'\ :sub:`11` 1403 - Y'\ :sub:`12` 1404 - Y'\ :sub:`13` 1405 * - start0 + 8: 1406 - Y'\ :sub:`20` 1407 - Y'\ :sub:`21` 1408 - Y'\ :sub:`22` 1409 - Y'\ :sub:`23` 1410 * - start0 + 12: 1411 - Y'\ :sub:`30` 1412 - Y'\ :sub:`31` 1413 - Y'\ :sub:`32` 1414 - Y'\ :sub:`33` 1415 * - 1416 * - start1 + 0: 1417 - Cb\ :sub:`00` 1418 - Cb\ :sub:`01` 1419 - Cb\ :sub:`02` 1420 - Cb\ :sub:`03` 1421 * - start1 + 4: 1422 - Cb\ :sub:`10` 1423 - Cb\ :sub:`11` 1424 - Cb\ :sub:`12` 1425 - Cb\ :sub:`13` 1426 * - start1 + 8: 1427 - Cb\ :sub:`20` 1428 - Cb\ :sub:`21` 1429 - Cb\ :sub:`22` 1430 - Cb\ :sub:`23` 1431 * - start1 + 12: 1432 - Cb\ :sub:`20` 1433 - Cb\ :sub:`21` 1434 - Cb\ :sub:`32` 1435 - Cb\ :sub:`33` 1436 * - 1437 * - start2 + 0: 1438 - Cr\ :sub:`00` 1439 - Cr\ :sub:`01` 1440 - Cr\ :sub:`02` 1441 - Cr\ :sub:`03` 1442 * - start2 + 4: 1443 - Cr\ :sub:`10` 1444 - Cr\ :sub:`11` 1445 - Cr\ :sub:`12` 1446 - Cr\ :sub:`13` 1447 * - start2 + 8: 1448 - Cr\ :sub:`20` 1449 - Cr\ :sub:`21` 1450 - Cr\ :sub:`22` 1451 - Cr\ :sub:`23` 1452 * - start2 + 12: 1453 - Cr\ :sub:`30` 1454 - Cr\ :sub:`31` 1455 - Cr\ :sub:`32` 1456 - Cr\ :sub:`33` 1457