Mauro Carvalho Chehab | 82559ac | 2018-08-30 10:15:26 -0400 | [diff] [blame] | 1 | .. Permission is granted to copy, distribute and/or modify this |
| 2 | .. document under the terms of the GNU Free Documentation License, |
| 3 | .. Version 1.1 or any later version published by the Free Software |
| 4 | .. Foundation, with no Invariant Sections, no Front-Cover Texts |
| 5 | .. and no Back-Cover Texts. A copy of the license is included at |
| 6 | .. Documentation/media/uapi/fdl-appendix.rst. |
| 7 | .. |
| 8 | .. TODO: replace it to GFDL-1.1-or-later WITH no-invariant-sections |
| 9 | |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 10 | .. _V4L2-PIX-FMT-NV24: |
Mauro Carvalho Chehab | 9aff73d | 2016-07-07 16:16:21 -0300 | [diff] [blame] | 11 | .. _V4L2-PIX-FMT-NV42: |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 12 | |
| 13 | ****************************************************** |
| 14 | V4L2_PIX_FMT_NV24 ('NV24'), V4L2_PIX_FMT_NV42 ('NV42') |
| 15 | ****************************************************** |
| 16 | |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 17 | V4L2_PIX_FMT_NV42 |
| 18 | Formats with full horizontal and vertical chroma resolutions, also known |
| 19 | as YUV 4:4:4. One luminance and one chrominance plane with alternating |
| 20 | chroma samples as opposed to ``V4L2_PIX_FMT_YVU420`` |
| 21 | |
| 22 | |
| 23 | Description |
| 24 | =========== |
| 25 | |
| 26 | These are two-plane versions of the YUV 4:4:4 format. The three |
| 27 | components are separated into two sub-images or planes. The Y plane is |
| 28 | first, with each Y sample stored in one byte per pixel. For |
| 29 | ``V4L2_PIX_FMT_NV24``, a combined CbCr plane immediately follows the Y |
| 30 | plane in memory. The CbCr plane has the same width and height, in |
| 31 | pixels, as the Y plane (and the image). Each line contains one CbCr pair |
| 32 | per pixel, with each Cb and Cr sample stored in one byte. |
| 33 | ``V4L2_PIX_FMT_NV42`` is the same except that the Cb and Cr samples are |
| 34 | swapped, the CrCb plane starts with a Cr sample. |
| 35 | |
| 36 | If the Y plane has pad bytes after each row, then the CbCr plane has |
| 37 | twice as many pad bytes after its rows. |
| 38 | |
Mauro Carvalho Chehab | 056d2ee | 2016-07-04 13:58:01 -0300 | [diff] [blame] | 39 | **Byte Order.** |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 40 | Each cell is one byte. |
| 41 | |
| 42 | |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 43 | .. flat-table:: |
| 44 | :header-rows: 0 |
| 45 | :stub-columns: 0 |
Markus Heiser | 5377d91 | 2016-06-30 15:18:56 +0200 | [diff] [blame] | 46 | |
Laurent Pinchart | c2b66ca | 2016-09-05 08:44:34 -0300 | [diff] [blame] | 47 | * - start + 0: |
| 48 | - Y'\ :sub:`00` |
| 49 | - Y'\ :sub:`01` |
| 50 | - Y'\ :sub:`02` |
| 51 | - Y'\ :sub:`03` |
| 52 | * - start + 4: |
| 53 | - Y'\ :sub:`10` |
| 54 | - Y'\ :sub:`11` |
| 55 | - Y'\ :sub:`12` |
| 56 | - Y'\ :sub:`13` |
| 57 | * - start + 8: |
| 58 | - Y'\ :sub:`20` |
| 59 | - Y'\ :sub:`21` |
| 60 | - Y'\ :sub:`22` |
| 61 | - Y'\ :sub:`23` |
| 62 | * - start + 12: |
| 63 | - Y'\ :sub:`30` |
| 64 | - Y'\ :sub:`31` |
| 65 | - Y'\ :sub:`32` |
| 66 | - Y'\ :sub:`33` |
| 67 | * - start + 16: |
| 68 | - Cb\ :sub:`00` |
| 69 | - Cr\ :sub:`00` |
| 70 | - Cb\ :sub:`01` |
| 71 | - Cr\ :sub:`01` |
| 72 | - Cb\ :sub:`02` |
| 73 | - Cr\ :sub:`02` |
| 74 | - Cb\ :sub:`03` |
| 75 | - Cr\ :sub:`03` |
| 76 | * - start + 24: |
| 77 | - Cb\ :sub:`10` |
| 78 | - Cr\ :sub:`10` |
| 79 | - Cb\ :sub:`11` |
| 80 | - Cr\ :sub:`11` |
| 81 | - Cb\ :sub:`12` |
| 82 | - Cr\ :sub:`12` |
| 83 | - Cb\ :sub:`13` |
| 84 | - Cr\ :sub:`13` |
| 85 | * - start + 32: |
| 86 | - Cb\ :sub:`20` |
| 87 | - Cr\ :sub:`20` |
| 88 | - Cb\ :sub:`21` |
| 89 | - Cr\ :sub:`21` |
| 90 | - Cb\ :sub:`22` |
| 91 | - Cr\ :sub:`22` |
| 92 | - Cb\ :sub:`23` |
| 93 | - Cr\ :sub:`23` |
| 94 | * - start + 40: |
| 95 | - Cb\ :sub:`30` |
| 96 | - Cr\ :sub:`30` |
| 97 | - Cb\ :sub:`31` |
| 98 | - Cr\ :sub:`31` |
| 99 | - Cb\ :sub:`32` |
| 100 | - Cr\ :sub:`32` |
| 101 | - Cb\ :sub:`33` |
| 102 | - Cr\ :sub:`33` |