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.
8 .. TODO: replace it to GFDL-1.1-or-later WITH no-invariant-sections
19 These formats are designed to match the pixel formats of typical PC
20 graphics frame buffers. They occupy 8, 16, 24 or 32 bits per pixel.
21 These are all packed-pixel formats, meaning all the data for a pixel lie
22 next to each other in memory.
28 \setlength{\tabcolsep}{2pt}
30 .. tabularcolumns:: |p{2.8cm}|p{2.0cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|
35 .. flat-table:: Packed RGB Image Formats
41 - :cspan:`7` Byte 0 in memory
82 * .. _V4L2-PIX-FMT-RGB332:
84 - ``V4L2_PIX_FMT_RGB332``
96 * .. _V4L2-PIX-FMT-ARGB444:
98 - ``V4L2_PIX_FMT_ARGB444``
119 * .. _V4L2-PIX-FMT-XRGB444:
121 - ``V4L2_PIX_FMT_XRGB444``
142 * .. _V4L2-PIX-FMT-ARGB555:
144 - ``V4L2_PIX_FMT_ARGB555``
165 * .. _V4L2-PIX-FMT-XRGB555:
167 - ``V4L2_PIX_FMT_XRGB555``
188 * .. _V4L2-PIX-FMT-RGB565:
190 - ``V4L2_PIX_FMT_RGB565``
211 * .. _V4L2-PIX-FMT-ARGB555X:
213 - ``V4L2_PIX_FMT_ARGB555X``
234 * .. _V4L2-PIX-FMT-XRGB555X:
236 - ``V4L2_PIX_FMT_XRGB555X``
257 * .. _V4L2-PIX-FMT-RGB565X:
259 - ``V4L2_PIX_FMT_RGB565X``
280 * .. _V4L2-PIX-FMT-BGR24:
282 - ``V4L2_PIX_FMT_BGR24``
312 * .. _V4L2-PIX-FMT-RGB24:
314 - ``V4L2_PIX_FMT_RGB24``
344 * .. _V4L2-PIX-FMT-BGR666:
346 - ``V4L2_PIX_FMT_BGR666``
384 * .. _V4L2-PIX-FMT-ABGR32:
386 - ``V4L2_PIX_FMT_ABGR32``
424 * .. _V4L2-PIX-FMT-XBGR32:
426 - ``V4L2_PIX_FMT_XBGR32``
464 * .. _V4L2-PIX-FMT-BGRA32:
466 - ``V4L2_PIX_FMT_BGRA32``
504 * .. _V4L2-PIX-FMT-BGRX32:
506 - ``V4L2_PIX_FMT_BGRX32``
544 * .. _V4L2-PIX-FMT-RGBA32:
546 - ``V4L2_PIX_FMT_RGBA32``
584 * .. _V4L2-PIX-FMT-RGBX32:
586 - ``V4L2_PIX_FMT_RGBX32``
624 * .. _V4L2-PIX-FMT-ARGB32:
626 - ``V4L2_PIX_FMT_ARGB32``
664 * .. _V4L2-PIX-FMT-XRGB32:
666 - ``V4L2_PIX_FMT_XRGB32``
709 .. note:: Bit 7 is the most significant bit.
711 The usage and value of the alpha bits (a) in the ARGB and ABGR formats
712 (collectively referred to as alpha formats) depend on the device type
713 and hardware operation. :ref:`Capture <capture>` devices (including
714 capture queues of mem-to-mem devices) fill the alpha component in
715 memory. When the device outputs an alpha channel the alpha component
716 will have a meaningful value. Otherwise, when the device doesn't output
717 an alpha channel but can set the alpha bit to a user-configurable value,
718 the :ref:`V4L2_CID_ALPHA_COMPONENT <v4l2-alpha-component>` control
719 is used to specify that alpha value, and the alpha component of all
720 pixels will be set to the value specified by that control. Otherwise a
721 corresponding format without an alpha component (XRGB or XBGR) must be
722 used instead of an alpha format.
724 :ref:`Output <output>` devices (including output queues of mem-to-mem
725 devices and :ref:`video output overlay <osd>` devices) read the alpha
726 component from memory. When the device processes the alpha channel the
727 alpha component must be filled with meaningful values by applications.
728 Otherwise a corresponding format without an alpha component (XRGB or
729 XBGR) must be used instead of an alpha format.
731 The XRGB and XBGR formats contain undefined bits (-). Applications,
732 devices and drivers must ignore those bits, for both
733 :ref:`capture` and :ref:`output` devices.
736 Each cell is one byte.
743 .. tabularcolumns:: |p{3.1cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|p{0.8cm}|
745 .. flat-table:: RGB byte order
748 :widths: 11 3 3 3 3 3 3 3 3 3 3 3 3
807 Formats defined in :ref:`rgb-formats-deprecated` are deprecated and
808 must not be used by new drivers. They are documented here for reference.
809 The meaning of their alpha bits ``(a)`` are ill-defined and interpreted as in
810 either the corresponding ARGB or XRGB format, depending on the driver.
817 \setlength{\tabcolsep}{2pt}
819 .. tabularcolumns:: |p{2.6cm}|p{0.70cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|p{0.22cm}|
821 .. _rgb-formats-deprecated:
823 .. flat-table:: Deprecated Packed RGB Image Formats
829 - :cspan:`7` Byte 0 in memory
873 * .. _V4L2-PIX-FMT-RGB444:
875 - ``V4L2_PIX_FMT_RGB444``
896 * .. _V4L2-PIX-FMT-RGB555:
898 - ``V4L2_PIX_FMT_RGB555``
919 * .. _V4L2-PIX-FMT-RGB555X:
921 - ``V4L2_PIX_FMT_RGB555X``
942 * .. _V4L2-PIX-FMT-BGR32:
944 - ``V4L2_PIX_FMT_BGR32``
982 * .. _V4L2-PIX-FMT-RGB32:
984 - ``V4L2_PIX_FMT_RGB32``
1027 A test utility to determine which RGB formats a driver actually supports
1028 is available from the LinuxTV v4l-dvb repository. See
1029 `https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access