1 .. -*- coding: utf-8; mode: rst -*-
12 These formats are designed to match the pixel formats of typical PC
13 graphics frame buffers. They occupy 8, 16, 24 or 32 bits per pixel.
14 These are all packed-pixel formats, meaning all the data for a pixel lie
15 next to each other in memory.
21 \setlength{\tabcolsep}{2pt}
23 .. tabularcolumns:: |p{2.3cm}|p{1.6cm}|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}|
28 .. flat-table:: Packed RGB Image Formats
34 - :cspan:`7` Byte 0 in memory
75 * .. _V4L2-PIX-FMT-RGB332:
77 - ``V4L2_PIX_FMT_RGB332``
89 * .. _V4L2-PIX-FMT-ARGB444:
91 - ``V4L2_PIX_FMT_ARGB444``
112 * .. _V4L2-PIX-FMT-XRGB444:
114 - ``V4L2_PIX_FMT_XRGB444``
135 * .. _V4L2-PIX-FMT-ARGB555:
137 - ``V4L2_PIX_FMT_ARGB555``
158 * .. _V4L2-PIX-FMT-XRGB555:
160 - ``V4L2_PIX_FMT_XRGB555``
181 * .. _V4L2-PIX-FMT-RGB565:
183 - ``V4L2_PIX_FMT_RGB565``
204 * .. _V4L2-PIX-FMT-ARGB555X:
206 - ``V4L2_PIX_FMT_ARGB555X``
227 * .. _V4L2-PIX-FMT-XRGB555X:
229 - ``V4L2_PIX_FMT_XRGB555X``
250 * .. _V4L2-PIX-FMT-RGB565X:
252 - ``V4L2_PIX_FMT_RGB565X``
273 * .. _V4L2-PIX-FMT-BGR24:
275 - ``V4L2_PIX_FMT_BGR24``
305 * .. _V4L2-PIX-FMT-RGB24:
307 - ``V4L2_PIX_FMT_RGB24``
337 * .. _V4L2-PIX-FMT-BGR666:
339 - ``V4L2_PIX_FMT_BGR666``
377 * .. _V4L2-PIX-FMT-ABGR32:
379 - ``V4L2_PIX_FMT_ABGR32``
417 * .. _V4L2-PIX-FMT-XBGR32:
419 - ``V4L2_PIX_FMT_XBGR32``
457 * .. _V4L2-PIX-FMT-ARGB32:
459 - ``V4L2_PIX_FMT_ARGB32``
497 * .. _V4L2-PIX-FMT-XRGB32:
499 - ``V4L2_PIX_FMT_XRGB32``
542 .. note:: Bit 7 is the most significant bit.
544 The usage and value of the alpha bits (a) in the ARGB and ABGR formats
545 (collectively referred to as alpha formats) depend on the device type
546 and hardware operation. :ref:`Capture <capture>` devices (including
547 capture queues of mem-to-mem devices) fill the alpha component in
548 memory. When the device outputs an alpha channel the alpha component
549 will have a meaningful value. Otherwise, when the device doesn't output
550 an alpha channel but can set the alpha bit to a user-configurable value,
551 the :ref:`V4L2_CID_ALPHA_COMPONENT <v4l2-alpha-component>` control
552 is used to specify that alpha value, and the alpha component of all
553 pixels will be set to the value specified by that control. Otherwise a
554 corresponding format without an alpha component (XRGB or XBGR) must be
555 used instead of an alpha format.
557 :ref:`Output <output>` devices (including output queues of mem-to-mem
558 devices and :ref:`video output overlay <osd>` devices) read the alpha
559 component from memory. When the device processes the alpha channel the
560 alpha component must be filled with meaningful values by applications.
561 Otherwise a corresponding format without an alpha component (XRGB or
562 XBGR) must be used instead of an alpha format.
564 The XRGB and XBGR formats contain undefined bits (-). Applications,
565 devices and drivers must ignore those bits, for both
566 :ref:`capture` and :ref:`output` devices.
569 Each cell is one byte.
576 .. 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}|
578 .. flat-table:: RGB byte order
581 :widths: 11 3 3 3 3 3 3 3 3 3 3 3 3
640 Formats defined in :ref:`rgb-formats-deprecated` are deprecated and
641 must not be used by new drivers. They are documented here for reference.
642 The meaning of their alpha bits ``(a)`` are ill-defined and interpreted as in
643 either the corresponding ARGB or XRGB format, depending on the driver.
650 \setlength{\tabcolsep}{2pt}
652 .. tabularcolumns:: |p{2.2cm}|p{0.60cm}|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}|
654 .. _rgb-formats-deprecated:
656 .. flat-table:: Deprecated Packed RGB Image Formats
662 - :cspan:`7` Byte 0 in memory
706 * .. _V4L2-PIX-FMT-RGB444:
708 - ``V4L2_PIX_FMT_RGB444``
729 * .. _V4L2-PIX-FMT-RGB555:
731 - ``V4L2_PIX_FMT_RGB555``
752 * .. _V4L2-PIX-FMT-RGB555X:
754 - ``V4L2_PIX_FMT_RGB555X``
775 * .. _V4L2-PIX-FMT-BGR32:
777 - ``V4L2_PIX_FMT_BGR32``
815 * .. _V4L2-PIX-FMT-RGB32:
817 - ``V4L2_PIX_FMT_RGB32``
860 A test utility to determine which RGB formats a driver actually supports
861 is available from the LinuxTV v4l-dvb repository. See
862 `https://linuxtv.org/repo/ <https://linuxtv.org/repo/>`__ for access