^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) .. c:namespace:: V4L
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) .. _hist-v4l2:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) ***********************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) Changes of the V4L2 API
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) ***********************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) Soon after the V4L API was added to the kernel it was criticised as too
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) inflexible. In August 1998 Bill Dirks proposed a number of improvements
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) and began to work on documentation, example drivers and applications.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) With the help of other volunteers this eventually became the V4L2 API,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) not just an extension but a replacement for the V4L API. However it took
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) another four years and two stable kernel releases until the new API was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) finally accepted for inclusion into the kernel in its present form.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) Early Versions
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) ==============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 1998-08-20: First version.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 1998-08-27: The :c:func:`select()` function was introduced.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 1998-09-10: New video standard interface.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 1998-09-18: The ``VIDIOC_NONCAP`` ioctl was replaced by the otherwise
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) meaningless ``O_TRUNC`` :c:func:`open()` flag, and the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) aliases ``O_NONCAP`` and ``O_NOIO`` were defined. Applications can set
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) this flag if they intend to access controls only, as opposed to capture
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) applications which need exclusive access. The ``VIDEO_STD_XXX``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) identifiers are now ordinals instead of flags, and the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) ``video_std_construct()`` helper function takes id and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) transmission arguments.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 1998-09-28: Revamped video standard. Made video controls individually
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) enumerable.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 1998-10-02: The ``id`` field was removed from
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) struct ``video_standard`` and the color subcarrier fields were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) renamed. The :ref:`VIDIOC_QUERYSTD` ioctl was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) renamed to :ref:`VIDIOC_ENUMSTD`,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) :ref:`VIDIOC_G_INPUT <VIDIOC_G_INPUT>` to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) :ref:`VIDIOC_ENUMINPUT`. A first draft of the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) Codec API was released.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) 1998-11-08: Many minor changes. Most symbols have been renamed. Some
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) material changes to struct v4l2_capability.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) 1998-11-12: The read/write directon of some ioctls was misdefined.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) 1998-11-14: ``V4L2_PIX_FMT_RGB24`` changed to ``V4L2_PIX_FMT_BGR24``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) and ``V4L2_PIX_FMT_RGB32`` changed to ``V4L2_PIX_FMT_BGR32``. Audio
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) controls are now accessible with the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) :ref:`VIDIOC_G_CTRL <VIDIOC_G_CTRL>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) :ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls under names starting
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) with ``V4L2_CID_AUDIO``. The ``V4L2_MAJOR`` define was removed from
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) ``videodev.h`` since it was only used once in the ``videodev`` kernel
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) module. The ``YUV422`` and ``YUV411`` planar image formats were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) 1998-11-28: A few ioctl symbols changed. Interfaces for codecs and video
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) output devices were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) 1999-01-14: A raw VBI capture interface was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) 1999-01-19: The ``VIDIOC_NEXTBUF`` ioctl was removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) V4L2 Version 0.16 1999-01-31
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) 1999-01-27: There is now one QBUF ioctl, VIDIOC_QWBUF and VIDIOC_QRBUF
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) are gone. VIDIOC_QBUF takes a v4l2_buffer as a parameter. Added
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) digital zoom (cropping) controls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) V4L2 Version 0.18 1999-03-16
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) Added a v4l to V4L2 ioctl compatibility layer to videodev.c. Driver
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) writers, this changes how you implement your ioctl handler. See the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) Driver Writer's Guide. Added some more control id codes.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 81)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 82) V4L2 Version 0.19 1999-06-05
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 83) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 84)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 85) 1999-03-18: Fill in the category and catname fields of v4l2_queryctrl
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 86) objects before passing them to the driver. Required a minor change to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 87) the VIDIOC_QUERYCTRL handlers in the sample drivers.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 88)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 89) 1999-03-31: Better compatibility for v4l memory capture ioctls. Requires
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 90) changes to drivers to fully support new compatibility features, see
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 91) Driver Writer's Guide and v4l2cap.c. Added new control IDs:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 92) V4L2_CID_HFLIP, _VFLIP. Changed V4L2_PIX_FMT_YUV422P to _YUV422P,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 93) and _YUV411P to _YUV411P.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 94)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 95) 1999-04-04: Added a few more control IDs.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 96)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 97) 1999-04-07: Added the button control type.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 98)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 99) 1999-05-02: Fixed a typo in videodev.h, and added the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100) V4L2_CTRL_FLAG_GRAYED (later V4L2_CTRL_FLAG_GRABBED) flag.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102) 1999-05-20: Definition of VIDIOC_G_CTRL was wrong causing a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103) malfunction of this ioctl.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105) 1999-06-05: Changed the value of V4L2_CID_WHITENESS.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107) V4L2 Version 0.20 (1999-09-10)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108) ==============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110) Version 0.20 introduced a number of changes which were *not backward
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111) compatible* with 0.19 and earlier versions. Purpose of these changes was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112) to simplify the API, while making it more extensible and following
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113) common Linux driver API conventions.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115) 1. Some typos in ``V4L2_FMT_FLAG`` symbols were fixed. struct v4l2_clip
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116) was changed for compatibility with v4l. (1999-08-30)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118) 2. ``V4L2_TUNER_SUB_LANG1`` was added. (1999-09-05)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 120) 3. All ioctl() commands that used an integer argument now take a pointer
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 121) to an integer. Where it makes sense, ioctls will return the actual
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 122) new value in the integer pointed to by the argument, a common
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 123) convention in the V4L2 API. The affected ioctls are: VIDIOC_PREVIEW,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 124) VIDIOC_STREAMON, VIDIOC_STREAMOFF, VIDIOC_S_FREQ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 125) VIDIOC_S_INPUT, VIDIOC_S_OUTPUT, VIDIOC_S_EFFECT. For example
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 126)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 127) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 128)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 129) err = ioctl (fd, VIDIOC_XXX, V4L2_XXX);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 130)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 131) becomes
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 132)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 133) .. code-block:: c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 134)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 135) int a = V4L2_XXX; err = ioctl(fd, VIDIOC_XXX, &a);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 136)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 137) 4. All the different get- and set-format commands were swept into one
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 138) :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 139) :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl taking a union and a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 140) type field selecting the union member as parameter. Purpose is to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 141) simplify the API by eliminating several ioctls and to allow new and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 142) driver private data streams without adding new ioctls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 143)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 144) This change obsoletes the following ioctls: ``VIDIOC_S_INFMT``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 145) ``VIDIOC_G_INFMT``, ``VIDIOC_S_OUTFMT``, ``VIDIOC_G_OUTFMT``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 146) ``VIDIOC_S_VBIFMT`` and ``VIDIOC_G_VBIFMT``. The image format
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 147) struct v4l2_format was renamed to struct v4l2_pix_format, while
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 148) struct v4l2_format is now the envelopping structure
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 149) for all format negotiations.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 150)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 151) 5. Similar to the changes above, the ``VIDIOC_G_PARM`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 152) ``VIDIOC_S_PARM`` ioctls were merged with ``VIDIOC_G_OUTPARM`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 153) ``VIDIOC_S_OUTPARM``. A ``type`` field in the new struct v4l2_streamparm
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 154) selects the respective union member.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 155)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 156) This change obsoletes the ``VIDIOC_G_OUTPARM`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 157) ``VIDIOC_S_OUTPARM`` ioctls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 158)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 159) 6. Control enumeration was simplified, and two new control flags were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 160) introduced and one dropped. The ``catname`` field was replaced by a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 161) ``group`` field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 162)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 163) Drivers can now flag unsupported and temporarily unavailable controls
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 164) with ``V4L2_CTRL_FLAG_DISABLED`` and ``V4L2_CTRL_FLAG_GRABBED``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 165) respectively. The ``group`` name indicates a possibly narrower
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 166) classification than the ``category``. In other words, there may be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 167) multiple groups within a category. Controls within a group would
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 168) typically be drawn within a group box. Controls in different
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 169) categories might have a greater separation, or may even appear in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 170) separate windows.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 171)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 172) 7. The struct v4l2_buffer ``timestamp`` was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 173) changed to a 64 bit integer, containing the sampling or output time
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 174) of the frame in nanoseconds. Additionally timestamps will be in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 175) absolute system time, not starting from zero at the beginning of a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 176) stream. The data type name for timestamps is stamp_t, defined as a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 177) signed 64-bit integer. Output devices should not send a buffer out
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 178) until the time in the timestamp field has arrived. I would like to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 179) follow SGI's lead, and adopt a multimedia timestamping system like
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 180) their UST (Unadjusted System Time). See
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 181) http://web.archive.org/web/\*/http://reality.sgi.com
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 182) /cpirazzi_engr/lg/time/intro.html. UST uses timestamps that are
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 183) 64-bit signed integers (not struct timeval's) and given in nanosecond
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 184) units. The UST clock starts at zero when the system is booted and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 185) runs continuously and uniformly. It takes a little over 292 years for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 186) UST to overflow. There is no way to set the UST clock. The regular
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 187) Linux time-of-day clock can be changed periodically, which would
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 188) cause errors if it were being used for timestamping a multimedia
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 189) stream. A real UST style clock will require some support in the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 190) kernel that is not there yet. But in anticipation, I will change the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 191) timestamp field to a 64-bit integer, and I will change the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 192) v4l2_masterclock_gettime() function (used only by drivers) to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 193) return a 64-bit integer.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 194)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 195) 8. A ``sequence`` field was added to struct v4l2_buffer. The ``sequence``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 196) field counts captured frames, it is ignored by output devices. When a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 197) capture driver drops a frame, the sequence number of that frame is skipped.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 198)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 199) V4L2 Version 0.20 incremental changes
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 200) =====================================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 201)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 202) 1999-12-23: In struct v4l2_vbi_format the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 203) ``reserved1`` field became ``offset``. Previously drivers were required
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 204) to clear the ``reserved1`` field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 205)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 206) 2000-01-13: The ``V4L2_FMT_FLAG_NOT_INTERLACED`` flag was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 207)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 208) 2000-07-31: The ``linux/poll.h`` header is now included by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 209) ``videodev.h`` for compatibility with the original ``videodev.h`` file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 210)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 211) 2000-11-20: ``V4L2_TYPE_VBI_OUTPUT`` and ``V4L2_PIX_FMT_Y41P`` were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 212) added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 213)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 214) 2000-11-25: ``V4L2_TYPE_VBI_INPUT`` was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 215)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 216) 2000-12-04: A couple typos in symbol names were fixed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 217)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 218) 2001-01-18: To avoid namespace conflicts the ``fourcc`` macro defined in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 219) the ``videodev.h`` header file was renamed to ``v4l2_fourcc``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 220)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 221) 2001-01-25: A possible driver-level compatibility problem between the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 222) ``videodev.h`` file in Linux 2.4.0 and the ``videodev.h`` file included
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 223) in the ``videodevX`` patch was fixed. Users of an earlier version of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 224) ``videodevX`` on Linux 2.4.0 should recompile their V4L and V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 225) drivers.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 226)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 227) 2001-01-26: A possible kernel-level incompatibility between the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 228) ``videodev.h`` file in the ``videodevX`` patch and the ``videodev.h``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 229) file in Linux 2.2.x with devfs patches applied was fixed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 230)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 231) 2001-03-02: Certain V4L ioctls which pass data in both direction
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 232) although they are defined with read-only parameter, did not work
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 233) correctly through the backward compatibility layer. [Solution?]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 234)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 235) 2001-04-13: Big endian 16-bit RGB formats were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 236)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 237) 2001-09-17: New YUV formats and the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 238) :ref:`VIDIOC_G_FREQUENCY <VIDIOC_G_FREQUENCY>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 239) :ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>` ioctls were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 240) (The old ``VIDIOC_G_FREQ`` and ``VIDIOC_S_FREQ`` ioctls did not take
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 241) multiple tuners into account.)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 242)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 243) 2000-09-18: ``V4L2_BUF_TYPE_VBI`` was added. This may *break
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 244) compatibility* as the :ref:`VIDIOC_G_FMT <VIDIOC_G_FMT>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 245) :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctls may fail now if the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 246) struct ``v4l2_fmt`` ``type`` field does not contain
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 247) ``V4L2_BUF_TYPE_VBI``. In the documentation of the struct v4l2_vbi_format`,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 248) the ``offset`` field the ambiguous phrase "rising edge" was changed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 249) "leading edge".
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 250)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 251) V4L2 Version 0.20 2000-11-23
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 252) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 253)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 254) A number of changes were made to the raw VBI interface.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 255)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 256) 1. Figures clarifying the line numbering scheme were added to the V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 257) API specification. The ``start``\ [0] and ``start``\ [1] fields no
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 258) longer count line numbers beginning at zero. Rationale: a) The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 259) previous definition was unclear. b) The ``start``\ [] values are
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 260) ordinal numbers. c) There is no point in inventing a new line
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 261) numbering scheme. We now use line number as defined by ITU-R, period.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 262) Compatibility: Add one to the start values. Applications depending on
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 263) the previous semantics may not function correctly.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 264)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 265) 2. The restriction "count[0] > 0 and count[1] > 0" has been relaxed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 266) "(count[0] + count[1]) > 0". Rationale: Drivers may allocate
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 267) resources at scan line granularity and some data services are
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 268) transmitted only on the first field. The comment that both ``count``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 269) values will usually be equal is misleading and pointless and has been
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 270) removed. This change *breaks compatibility* with earlier versions:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 271) Drivers may return ``EINVAL``, applications may not function correctly.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 272)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 273) 3. Drivers are again permitted to return negative (unknown) start values
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 274) as proposed earlier. Why this feature was dropped is unclear. This
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 275) change may *break compatibility* with applications depending on the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 276) start values being positive. The use of ``EBUSY`` and ``EINVAL``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 277) error codes with the :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 278) clarified. The ``EBUSY`` error code was finally documented, and the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 279) ``reserved2`` field which was previously mentioned only in the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 280) ``videodev.h`` header file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 281)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 282) 4. New buffer types ``V4L2_TYPE_VBI_INPUT`` and ``V4L2_TYPE_VBI_OUTPUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 283) were added. The former is an alias for the old ``V4L2_TYPE_VBI``, the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 284) latter was missing in the ``videodev.h`` file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 285)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 286) V4L2 Version 0.20 2002-07-25
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 287) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 288)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 289) Added sliced VBI interface proposal.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 290)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 291) V4L2 in Linux 2.5.46, 2002-10
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 292) =============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 293)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 294) Around October-November 2002, prior to an announced feature freeze of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 295) Linux 2.5, the API was revised, drawing from experience with V4L2 0.20.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 296) This unnamed version was finally merged into Linux 2.5.46.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 297)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 298) 1. As specified in :ref:`related`, drivers must make related device
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 299) functions available under all minor device numbers.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 300)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 301) 2. The :c:func:`open()` function requires access mode
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 302) ``O_RDWR`` regardless of the device type. All V4L2 drivers
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 303) exchanging data with applications must support the ``O_NONBLOCK``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 304) flag. The ``O_NOIO`` flag, a V4L2 symbol which aliased the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 305) meaningless ``O_TRUNC`` to indicate accesses without data exchange
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 306) (panel applications) was dropped. Drivers must stay in "panel mode"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 307) until the application attempts to initiate a data exchange, see
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 308) :ref:`open`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 309)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 310) 3. The struct v4l2_capability changed
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 311) dramatically. Note that also the size of the structure changed,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 312) which is encoded in the ioctl request code, thus older V4L2 devices
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 313) will respond with an ``EINVAL`` error code to the new
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 314) :ref:`VIDIOC_QUERYCAP` ioctl.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 315)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 316) There are new fields to identify the driver, a new RDS device
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 317) function ``V4L2_CAP_RDS_CAPTURE``, the ``V4L2_CAP_AUDIO`` flag
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 318) indicates if the device has any audio connectors, another I/O
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 319) capability ``V4L2_CAP_ASYNCIO`` can be flagged. In response to these
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 320) changes the ``type`` field became a bit set and was merged into the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 321) ``flags`` field. ``V4L2_FLAG_TUNER`` was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 322) ``V4L2_CAP_TUNER``, ``V4L2_CAP_VIDEO_OVERLAY`` replaced
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 323) ``V4L2_FLAG_PREVIEW`` and ``V4L2_CAP_VBI_CAPTURE`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 324) ``V4L2_CAP_VBI_OUTPUT`` replaced ``V4L2_FLAG_DATA_SERVICE``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 325) ``V4L2_FLAG_READ`` and ``V4L2_FLAG_WRITE`` were merged into
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 326) ``V4L2_CAP_READWRITE``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 327)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 328) The redundant fields ``inputs``, ``outputs`` and ``audios`` were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 329) removed. These properties can be determined as described in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 330) :ref:`video` and :ref:`audio`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 331)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 332) The somewhat volatile and therefore barely useful fields
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 333) ``maxwidth``, ``maxheight``, ``minwidth``, ``minheight``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 334) ``maxframerate`` were removed. This information is available as
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 335) described in :ref:`format` and :ref:`standard`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 336)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 337) ``V4L2_FLAG_SELECT`` was removed. We believe the select() function
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 338) is important enough to require support of it in all V4L2 drivers
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 339) exchanging data with applications. The redundant
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 340) ``V4L2_FLAG_MONOCHROME`` flag was removed, this information is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 341) available as described in :ref:`format`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 342)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 343) 4. In struct v4l2_input the ``assoc_audio``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 344) field and the ``capability`` field and its only flag
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 345) ``V4L2_INPUT_CAP_AUDIO`` was replaced by the new ``audioset`` field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 346) Instead of linking one video input to one audio input this field
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 347) reports all audio inputs this video input combines with.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 348)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 349) New fields are ``tuner`` (reversing the former link from tuners to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 350) video inputs), ``std`` and ``status``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 351)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 352) Accordingly struct v4l2_output lost its
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 353) ``capability`` and ``assoc_audio`` fields. ``audioset``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 354) ``modulator`` and ``std`` where added instead.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 355)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 356) 5. The struct v4l2_audio field ``audio`` was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 357) renamed to ``index``, for consistency with other structures. A new
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 358) capability flag ``V4L2_AUDCAP_STEREO`` was added to indicated if the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 359) audio input in question supports stereo sound.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 360) ``V4L2_AUDCAP_EFFECTS`` and the corresponding ``V4L2_AUDMODE`` flags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 361) where removed. This can be easily implemented using controls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 362) (However the same applies to AVL which is still there.)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 363)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 364) Again for consistency the struct v4l2_audioout field ``audio`` was renamed
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 365) to ``index``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 366)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 367) 6. The struct v4l2_tuner ``input`` field was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 368) replaced by an ``index`` field, permitting devices with multiple
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 369) tuners. The link between video inputs and tuners is now reversed,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 370) inputs point to their tuner. The ``std`` substructure became a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 371) simple set (more about this below) and moved into struct v4l2_input.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 372) A ``type`` field was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 373)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 374) Accordingly in struct v4l2_modulator the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 375) ``output`` was replaced by an ``index`` field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 376)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 377) In struct v4l2_frequency the ``port``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 378) field was replaced by a ``tuner`` field containing the respective
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 379) tuner or modulator index number. A tuner ``type`` field was added
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 380) and the ``reserved`` field became larger for future extensions
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 381) (satellite tuners in particular).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 382)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 383) 7. The idea of completely transparent video standards was dropped.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 384) Experience showed that applications must be able to work with video
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 385) standards beyond presenting the user a menu. Instead of enumerating
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 386) supported standards with an ioctl applications can now refer to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 387) standards by :ref:`v4l2_std_id <v4l2-std-id>` and symbols
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 388) defined in the ``videodev2.h`` header file. For details see
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 389) :ref:`standard`. The :ref:`VIDIOC_G_STD <VIDIOC_G_STD>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 390) :ref:`VIDIOC_S_STD <VIDIOC_G_STD>` now take a pointer to this
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 391) type as argument. :ref:`VIDIOC_QUERYSTD` was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 392) added to autodetect the received standard, if the hardware has this
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 393) capability. In struct v4l2_standard an
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 394) ``index`` field was added for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 395) :ref:`VIDIOC_ENUMSTD`. A
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 396) :ref:`v4l2_std_id <v4l2-std-id>` field named ``id`` was added as
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 397) machine readable identifier, also replacing the ``transmission``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 398) field. The misleading ``framerate`` field was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 399) ``frameperiod``. The now obsolete ``colorstandard`` information,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 400) originally needed to distguish between variations of standards, were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 401) removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 402)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 403) Struct ``v4l2_enumstd`` ceased to be.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 404) :ref:`VIDIOC_ENUMSTD` now takes a pointer to a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 405) struct v4l2_standard directly. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 406) information which standards are supported by a particular video
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 407) input or output moved into struct v4l2_input
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 408) and struct v4l2_output fields named ``std``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 409) respectively.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 410)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 411) 8. The struct :ref:`v4l2_queryctrl <v4l2-queryctrl>` fields
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 412) ``category`` and ``group`` did not catch on and/or were not
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 413) implemented as expected and therefore removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 414)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 415) 9. The :ref:`VIDIOC_TRY_FMT <VIDIOC_G_FMT>` ioctl was added to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 416) negotiate data formats as with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 417) :ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>`, but without the overhead of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 418) programming the hardware and regardless of I/O in progress.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 419)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 420) In struct v4l2_format the ``fmt`` union was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 421) extended to contain struct v4l2_window. All
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 422) image format negotiations are now possible with ``VIDIOC_G_FMT``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 423) ``VIDIOC_S_FMT`` and ``VIDIOC_TRY_FMT``; ioctl. The ``VIDIOC_G_WIN``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 424) and ``VIDIOC_S_WIN`` ioctls to prepare for a video overlay were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 425) removed. The ``type`` field changed to type enum v4l2_buf_type and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 426) the buffer type names changed as follows.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 427)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 428)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 429) .. flat-table::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 430) :header-rows: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 431) :stub-columns: 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 432)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 433) * - Old defines
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 434) - enum v4l2_buf_type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 435) * - ``V4L2_BUF_TYPE_CAPTURE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 436) - ``V4L2_BUF_TYPE_VIDEO_CAPTURE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 437) * - ``V4L2_BUF_TYPE_CODECIN``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 438) - Omitted for now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 439) * - ``V4L2_BUF_TYPE_CODECOUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 440) - Omitted for now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 441) * - ``V4L2_BUF_TYPE_EFFECTSIN``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 442) - Omitted for now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 443) * - ``V4L2_BUF_TYPE_EFFECTSIN2``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 444) - Omitted for now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 445) * - ``V4L2_BUF_TYPE_EFFECTSOUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 446) - Omitted for now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 447) * - ``V4L2_BUF_TYPE_VIDEOOUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 448) - ``V4L2_BUF_TYPE_VIDEO_OUTPUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 449) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 450) - ``V4L2_BUF_TYPE_VIDEO_OVERLAY``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 451) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 452) - ``V4L2_BUF_TYPE_VBI_CAPTURE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 453) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 454) - ``V4L2_BUF_TYPE_VBI_OUTPUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 455) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 456) - ``V4L2_BUF_TYPE_SLICED_VBI_CAPTURE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 457) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 458) - ``V4L2_BUF_TYPE_SLICED_VBI_OUTPUT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 459) * - ``V4L2_BUF_TYPE_PRIVATE_BASE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 460) - ``V4L2_BUF_TYPE_PRIVATE`` (but this is deprecated)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 461)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 462) 10. In struct v4l2_fmtdesc a enum v4l2_buf_type field named ``type`` was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 463) added as in struct v4l2_format. The ``VIDIOC_ENUM_FBUFFMT`` ioctl is no
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 464) longer needed and was removed. These calls can be replaced by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 465) :ref:`VIDIOC_ENUM_FMT` with type ``V4L2_BUF_TYPE_VIDEO_OVERLAY``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 466)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 467) 11. In struct v4l2_pix_format the ``depth``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 468) field was removed, assuming applications which recognize the format
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 469) by its four-character-code already know the color depth, and others
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 470) do not care about it. The same rationale lead to the removal of the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 471) ``V4L2_FMT_FLAG_COMPRESSED`` flag. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 472) ``V4L2_FMT_FLAG_SWCONVECOMPRESSED`` flag was removed because drivers
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 473) are not supposed to convert images in kernel space. A user library
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 474) of conversion functions should be provided instead. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 475) ``V4L2_FMT_FLAG_BYTESPERLINE`` flag was redundant. Applications can
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 476) set the ``bytesperline`` field to zero to get a reasonable default.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 477) Since the remaining flags were replaced as well, the ``flags`` field
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 478) itself was removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 479)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 480) The interlace flags were replaced by a enum v4l2_field value in a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 481) newly added ``field`` field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 482)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 483) .. flat-table::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 484) :header-rows: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 485) :stub-columns: 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 486)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 487) * - Old flag
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 488) - enum v4l2_field
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 489) * - ``V4L2_FMT_FLAG_NOT_INTERLACED``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 490) - ?
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 491) * - ``V4L2_FMT_FLAG_INTERLACED`` = ``V4L2_FMT_FLAG_COMBINED``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 492) - ``V4L2_FIELD_INTERLACED``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 493) * - ``V4L2_FMT_FLAG_TOPFIELD`` = ``V4L2_FMT_FLAG_ODDFIELD``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 494) - ``V4L2_FIELD_TOP``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 495) * - ``V4L2_FMT_FLAG_BOTFIELD`` = ``V4L2_FMT_FLAG_EVENFIELD``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 496) - ``V4L2_FIELD_BOTTOM``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 497) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 498) - ``V4L2_FIELD_SEQ_TB``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 499) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 500) - ``V4L2_FIELD_SEQ_BT``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 501) * - ``-``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 502) - ``V4L2_FIELD_ALTERNATE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 503)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 504) The color space flags were replaced by a enum v4l2_colorspace value in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 505) a newly added ``colorspace`` field, where one of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 506) ``V4L2_COLORSPACE_SMPTE170M``, ``V4L2_COLORSPACE_BT878``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 507) ``V4L2_COLORSPACE_470_SYSTEM_M`` or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 508) ``V4L2_COLORSPACE_470_SYSTEM_BG`` replaces ``V4L2_FMT_CS_601YUV``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 509)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 510) 12. In struct v4l2_requestbuffers the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 511) ``type`` field was properly defined as enum v4l2_buf_type. Buffer types
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 512) changed as mentioned above. A new ``memory`` field of type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 513) enum v4l2_memory was added to distinguish between
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 514) I/O methods using buffers allocated by the driver or the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 515) application. See :ref:`io` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 516)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 517) 13. In struct v4l2_buffer the ``type`` field was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 518) properly defined as enum v4l2_buf_type.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 519) Buffer types changed as mentioned above. A ``field`` field of type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 520) enum v4l2_field was added to indicate if a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 521) buffer contains a top or bottom field. The old field flags were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 522) removed. Since no unadjusted system time clock was added to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 523) kernel as planned, the ``timestamp`` field changed back from type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 524) stamp_t, an unsigned 64 bit integer expressing the sample time in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 525) nanoseconds, to struct timeval. With the addition
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 526) of a second memory mapping method the ``offset`` field moved into
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 527) union ``m``, and a new ``memory`` field of type enum v4l2_memory
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 528) was added to distinguish between
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 529) I/O methods. See :ref:`io` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 530)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 531) The ``V4L2_BUF_REQ_CONTIG`` flag was used by the V4L compatibility
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 532) layer, after changes to this code it was no longer needed. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 533) ``V4L2_BUF_ATTR_DEVICEMEM`` flag would indicate if the buffer was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 534) indeed allocated in device memory rather than DMA-able system
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 535) memory. It was barely useful and so was removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 536)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 537) 14. In struct v4l2_framebuffer the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 538) ``base[3]`` array anticipating double- and triple-buffering in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 539) off-screen video memory, however without defining a synchronization
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 540) mechanism, was replaced by a single pointer. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 541) ``V4L2_FBUF_CAP_SCALEUP`` and ``V4L2_FBUF_CAP_SCALEDOWN`` flags were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 542) removed. Applications can determine this capability more accurately
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 543) using the new cropping and scaling interface. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 544) ``V4L2_FBUF_CAP_CLIPPING`` flag was replaced by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 545) ``V4L2_FBUF_CAP_LIST_CLIPPING`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 546) ``V4L2_FBUF_CAP_BITMAP_CLIPPING``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 547)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 548) 15. In struct v4l2_clip the ``x``, ``y``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 549) ``width`` and ``height`` field moved into a ``c`` substructure of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 550) type struct v4l2_rect. The ``x`` and ``y``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 551) fields were renamed to ``left`` and ``top``, i. e. offsets to a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 552) context dependent origin.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 553)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 554) 16. In struct v4l2_window the ``x``, ``y``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 555) ``width`` and ``height`` field moved into a ``w`` substructure as
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 556) above. A ``field`` field of type enum v4l2_field was added to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 557) distinguish between field and frame (interlaced) overlay.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 558)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 559) 17. The digital zoom interface, including struct ``v4l2_zoomcap``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 560) struct ``v4l2_zoom``, ``V4L2_ZOOM_NONCAP`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 561) ``V4L2_ZOOM_WHILESTREAMING`` was replaced by a new cropping and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 562) scaling interface. The previously unused
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 563) struct v4l2_cropcap and struct v4l2_crop
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 564) where redefined for this purpose. See :ref:`crop` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 565)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 566) 18. In struct v4l2_vbi_format the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 567) ``SAMPLE_FORMAT`` field now contains a four-character-code as used
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 568) to identify video image formats and ``V4L2_PIX_FMT_GREY`` replaces
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 569) the ``V4L2_VBI_SF_UBYTE`` define. The ``reserved`` field was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 570) extended.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 571)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 572) 19. In struct v4l2_captureparm the type of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 573) the ``timeperframe`` field changed from unsigned long to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 574) struct v4l2_fract. This allows the accurate
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 575) expression of multiples of the NTSC-M frame rate 30000 / 1001. A new
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 576) field ``readbuffers`` was added to control the driver behaviour in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 577) read I/O mode.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 578)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 579) Similar changes were made to struct v4l2_outputparm.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 580)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 581) 20. The struct ``v4l2_performance`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 582) ``VIDIOC_G_PERF`` ioctl were dropped. Except when using the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 583) :ref:`read/write I/O method <rw>`, which is limited anyway, this
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 584) information is already available to applications.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 585)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 586) 21. The example transformation from RGB to YCbCr color space in the old
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 587) V4L2 documentation was inaccurate, this has been corrected in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 588) :ref:`pixfmt`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 589)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 590) V4L2 2003-06-19
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 591) ===============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 592)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 593) 1. A new capability flag ``V4L2_CAP_RADIO`` was added for radio devices.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 594) Prior to this change radio devices would identify solely by having
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 595) exactly one tuner whose type field reads ``V4L2_TUNER_RADIO``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 596)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 597) 2. An optional driver access priority mechanism was added, see
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 598) :ref:`app-pri` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 599)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 600) 3. The audio input and output interface was found to be incomplete.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 601)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 602) Previously the :ref:`VIDIOC_G_AUDIO <VIDIOC_G_AUDIO>` ioctl would
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 603) enumerate the available audio inputs. An ioctl to determine the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 604) current audio input, if more than one combines with the current video
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 605) input, did not exist. So ``VIDIOC_G_AUDIO`` was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 606) ``VIDIOC_G_AUDIO_OLD``, this ioctl was removed on Kernel 2.6.39. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 607) :ref:`VIDIOC_ENUMAUDIO` ioctl was added to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 608) enumerate audio inputs, while
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 609) :ref:`VIDIOC_G_AUDIO <VIDIOC_G_AUDIO>` now reports the current
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 610) audio input.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 611)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 612) The same changes were made to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 613) :ref:`VIDIOC_G_AUDOUT <VIDIOC_G_AUDOUT>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 614) :ref:`VIDIOC_ENUMAUDOUT <VIDIOC_ENUMAUDOUT>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 615)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 616) Until further the "videodev" module will automatically translate
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 617) between the old and new ioctls, but drivers and applications must be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 618) updated to successfully compile again.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 619)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 620) 4. The :ref:`VIDIOC_OVERLAY` ioctl was incorrectly
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 621) defined with write-read parameter. It was changed to write-only,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 622) while the write-read version was renamed to ``VIDIOC_OVERLAY_OLD``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 623) The old ioctl was removed on Kernel 2.6.39. Until further the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 624) "videodev" kernel module will automatically translate to the new
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 625) version, so drivers must be recompiled, but not applications.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 626)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 627) 5. :ref:`overlay` incorrectly stated that clipping rectangles define
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 628) regions where the video can be seen. Correct is that clipping
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 629) rectangles define regions where *no* video shall be displayed and so
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 630) the graphics surface can be seen.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 631)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 632) 6. The :ref:`VIDIOC_S_PARM <VIDIOC_G_PARM>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 633) :ref:`VIDIOC_S_CTRL <VIDIOC_G_CTRL>` ioctls were defined with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 634) write-only parameter, inconsistent with other ioctls modifying their
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 635) argument. They were changed to write-read, while a ``_OLD`` suffix
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 636) was added to the write-only versions. The old ioctls were removed on
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 637) Kernel 2.6.39. Drivers and applications assuming a constant parameter
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 638) need an update.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 639)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 640) V4L2 2003-11-05
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 641) ===============
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 642)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 643) 1. In :ref:`pixfmt-rgb` the following pixel formats were incorrectly
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 644) transferred from Bill Dirks' V4L2 specification. Descriptions below
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 645) refer to bytes in memory, in ascending address order.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 646)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 647)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 648) .. flat-table::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 649) :header-rows: 1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 650) :stub-columns: 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 651)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 652) * - Symbol
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 653) - In this document prior to revision 0.5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 654) - Corrected
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 655) * - ``V4L2_PIX_FMT_RGB24``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 656) - B, G, R
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 657) - R, G, B
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 658) * - ``V4L2_PIX_FMT_BGR24``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 659) - R, G, B
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 660) - B, G, R
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 661) * - ``V4L2_PIX_FMT_RGB32``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 662) - B, G, R, X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 663) - R, G, B, X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 664) * - ``V4L2_PIX_FMT_BGR32``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 665) - R, G, B, X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 666) - B, G, R, X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 667)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 668) The ``V4L2_PIX_FMT_BGR24`` example was always correct.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 669)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 670) In :ref:`v4l-image-properties` the mapping of the V4L
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 671) ``VIDEO_PALETTE_RGB24`` and ``VIDEO_PALETTE_RGB32`` formats to V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 672) pixel formats was accordingly corrected.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 673)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 674) 2. Unrelated to the fixes above, drivers may still interpret some V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 675) RGB pixel formats differently. These issues have yet to be addressed,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 676) for details see :ref:`pixfmt-rgb`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 677)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 678) V4L2 in Linux 2.6.6, 2004-05-09
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 679) ===============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 680)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 681) 1. The :ref:`VIDIOC_CROPCAP` ioctl was incorrectly
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 682) defined with read-only parameter. It is now defined as write-read
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 683) ioctl, while the read-only version was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 684) ``VIDIOC_CROPCAP_OLD``. The old ioctl was removed on Kernel 2.6.39.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 685)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 686) V4L2 in Linux 2.6.8
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 687) ===================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 688)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 689) 1. A new field ``input`` (former ``reserved[0]``) was added to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 690) struct v4l2_buffer. Purpose of this
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 691) field is to alternate between video inputs (e. g. cameras) in step
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 692) with the video capturing process. This function must be enabled with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 693) the new ``V4L2_BUF_FLAG_INPUT`` flag. The ``flags`` field is no
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 694) longer read-only.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 695)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 696) V4L2 spec erratum 2004-08-01
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 697) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 698)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 699) 1. The return value of the :ref:`func-open` function was incorrectly
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 700) documented.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 701)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 702) 2. Audio output ioctls end in -AUDOUT, not -AUDIOOUT.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 703)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 704) 3. In the Current Audio Input example the ``VIDIOC_G_AUDIO`` ioctl took
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 705) the wrong argument.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 706)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 707) 4. The documentation of the :ref:`VIDIOC_QBUF` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 708) :ref:`VIDIOC_DQBUF <VIDIOC_QBUF>` ioctls did not mention the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 709) struct v4l2_buffer ``memory`` field. It was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 710) also missing from examples. Also on the ``VIDIOC_DQBUF`` page the ``EIO``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 711) error code was not documented.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 712)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 713) V4L2 in Linux 2.6.14
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 714) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 715)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 716) 1. A new sliced VBI interface was added. It is documented in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 717) :ref:`sliced` and replaces the interface first proposed in V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 718) specification 0.8.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 719)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 720) V4L2 in Linux 2.6.15
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 721) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 722)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 723) 1. The :ref:`VIDIOC_LOG_STATUS` ioctl was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 724)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 725) 2. New video standards ``V4L2_STD_NTSC_443``, ``V4L2_STD_SECAM_LC``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 726) ``V4L2_STD_SECAM_DK`` (a set of SECAM D, K and K1), and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 727) ``V4L2_STD_ATSC`` (a set of ``V4L2_STD_ATSC_8_VSB`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 728) ``V4L2_STD_ATSC_16_VSB``) were defined. Note the ``V4L2_STD_525_60``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 729) set now includes ``V4L2_STD_NTSC_443``. See also
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 730) :ref:`v4l2-std-id`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 731)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 732) 3. The ``VIDIOC_G_COMP`` and ``VIDIOC_S_COMP`` ioctl were renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 733) ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` respectively. Their
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 734) argument was replaced by a struct
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 735) ``v4l2_mpeg_compression`` pointer. (The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 736) ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` ioctls where removed
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 737) in Linux 2.6.25.)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 738)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 739) V4L2 spec erratum 2005-11-27
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 740) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 741)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 742) The capture example in :ref:`capture-example` called the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 743) :ref:`VIDIOC_S_CROP <VIDIOC_G_CROP>` ioctl without checking if
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 744) cropping is supported. In the video standard selection example in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 745) :ref:`standard` the :ref:`VIDIOC_S_STD <VIDIOC_G_STD>` call used
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 746) the wrong argument type.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 747)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 748) V4L2 spec erratum 2006-01-10
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 749) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 750)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 751) 1. The ``V4L2_IN_ST_COLOR_KILL`` flag in struct v4l2_input not only
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 752) indicates if the color killer is enabled, but also if it is active.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 753) (The color killer disables color decoding when it detects no color
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 754) in the video signal to improve the image quality.)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 755)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 756) 2. :ref:`VIDIOC_S_PARM <VIDIOC_G_PARM>` is a write-read ioctl, not
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 757) write-only as stated on its reference page. The ioctl changed in 2003
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 758) as noted above.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 759)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 760) V4L2 spec erratum 2006-02-03
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 761) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 762)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 763) 1. In struct v4l2_captureparm and struct v4l2_outputparm the ``timeperframe``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 764) field gives the time in seconds, not microseconds.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 765)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 766) V4L2 spec erratum 2006-02-04
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 767) ============================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 768)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 769) 1. The ``clips`` field in struct v4l2_window
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 770) must point to an array of struct v4l2_clip, not
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 771) a linked list, because drivers ignore the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 772) struct v4l2_clip. ``next`` pointer.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 773)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 774) V4L2 in Linux 2.6.17
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 775) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 776)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 777) 1. New video standard macros were added: ``V4L2_STD_NTSC_M_KR`` (NTSC M
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 778) South Korea), and the sets ``V4L2_STD_MN``, ``V4L2_STD_B``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 779) ``V4L2_STD_GH`` and ``V4L2_STD_DK``. The ``V4L2_STD_NTSC`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 780) ``V4L2_STD_SECAM`` sets now include ``V4L2_STD_NTSC_M_KR`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 781) ``V4L2_STD_SECAM_LC`` respectively.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 782)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 783) 2. A new ``V4L2_TUNER_MODE_LANG1_LANG2`` was defined to record both
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 784) languages of a bilingual program. The use of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 785) ``V4L2_TUNER_MODE_STEREO`` for this purpose is deprecated now. See
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 786) the :ref:`VIDIOC_G_TUNER <VIDIOC_G_TUNER>` section for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 787)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 788) V4L2 spec erratum 2006-09-23 (Draft 0.15)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 789) =========================================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 790)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 791) 1. In various places ``V4L2_BUF_TYPE_SLICED_VBI_CAPTURE`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 792) ``V4L2_BUF_TYPE_SLICED_VBI_OUTPUT`` of the sliced VBI interface were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 793) not mentioned along with other buffer types.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 794)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 795) 2. In :ref:`VIDIOC_G_AUDIO <VIDIOC_G_AUDIO>` it was clarified that the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 796) struct v4l2_audio ``mode`` field is a flags field.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 797)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 798) 3. :ref:`VIDIOC_QUERYCAP` did not mention the sliced VBI and radio
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 799) capability flags.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 800)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 801) 4. In :ref:`VIDIOC_G_FREQUENCY <VIDIOC_G_FREQUENCY>` it was clarified that
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 802) applications must initialize the tuner ``type`` field of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 803) struct v4l2_frequency before calling
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 804) :ref:`VIDIOC_S_FREQUENCY <VIDIOC_G_FREQUENCY>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 805)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 806) 5. The ``reserved`` array in struct v4l2_requestbuffers has 2 elements,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 807) not 32.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 808)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 809) 6. In :ref:`output` and :ref:`raw-vbi` the device file names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 810) ``/dev/vout`` which never caught on were replaced by ``/dev/video``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 811)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 812) 7. With Linux 2.6.15 the possible range for VBI device minor numbers was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 813) extended from 224-239 to 224-255. Accordingly device file names
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 814) ``/dev/vbi0`` to ``/dev/vbi31`` are possible now.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 815)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 816) V4L2 in Linux 2.6.18
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 817) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 818)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 819) 1. New ioctls :ref:`VIDIOC_G_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>`,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 820) :ref:`VIDIOC_S_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 821) :ref:`VIDIOC_TRY_EXT_CTRLS <VIDIOC_G_EXT_CTRLS>` were added, a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 822) flag to skip unsupported controls with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 823) :ref:`VIDIOC_QUERYCTRL`, new control types
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 824) ``V4L2_CTRL_TYPE_INTEGER64`` and ``V4L2_CTRL_TYPE_CTRL_CLASS``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 825) (enum v4l2_ctrl_type), and new control flags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 826) ``V4L2_CTRL_FLAG_READ_ONLY``, ``V4L2_CTRL_FLAG_UPDATE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 827) ``V4L2_CTRL_FLAG_INACTIVE`` and ``V4L2_CTRL_FLAG_SLIDER``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 828) (:ref:`control-flags`). See :ref:`extended-controls` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 829)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 830) V4L2 in Linux 2.6.19
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 831) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 832)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 833) 1. In struct v4l2_sliced_vbi_cap a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 834) buffer type field was added replacing a reserved field. Note on
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 835) architectures where the size of enum types differs from int types the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 836) size of the structure changed. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 837) :ref:`VIDIOC_G_SLICED_VBI_CAP <VIDIOC_G_SLICED_VBI_CAP>` ioctl
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 838) was redefined from being read-only to write-read. Applications must
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 839) initialize the type field and clear the reserved fields now. These
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 840) changes may *break the compatibility* with older drivers and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 841) applications.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 842)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 843) 2. The ioctls :ref:`VIDIOC_ENUM_FRAMESIZES`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 844) and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 845) :ref:`VIDIOC_ENUM_FRAMEINTERVALS`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 846) were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 847)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 848) 3. A new pixel format ``V4L2_PIX_FMT_RGB444`` (:ref:`pixfmt-rgb`) was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 849) added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 850)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 851) V4L2 spec erratum 2006-10-12 (Draft 0.17)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 852) =========================================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 853)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 854) 1. ``V4L2_PIX_FMT_HM12`` (:ref:`reserved-formats`) is a YUV 4:2:0, not
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 855) 4:2:2 format.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 856)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 857) V4L2 in Linux 2.6.21
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 858) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 859)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 860) 1. The ``videodev2.h`` header file is now dual licensed under GNU
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 861) General Public License version two or later, and under a 3-clause
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 862) BSD-style license.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 863)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 864) V4L2 in Linux 2.6.22
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 865) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 866)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 867) 1. Two new field orders ``V4L2_FIELD_INTERLACED_TB`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 868) ``V4L2_FIELD_INTERLACED_BT`` were added. See enum v4l2_field for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 869) details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 870)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 871) 2. Three new clipping/blending methods with a global or straight or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 872) inverted local alpha value were added to the video overlay interface.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 873) See the description of the :ref:`VIDIOC_G_FBUF <VIDIOC_G_FBUF>`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 874) and :ref:`VIDIOC_S_FBUF <VIDIOC_G_FBUF>` ioctls for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 875)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 876) A new ``global_alpha`` field was added to struct v4l2_window,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 877) extending the structure. This may **break compatibility** with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 878) applications using a struct v4l2_window directly. However the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 879) :ref:`VIDIOC_G/S/TRY_FMT <VIDIOC_G_FMT>` ioctls, which take a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 880) pointer to a struct v4l2_format parent structure
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 881) with padding bytes at the end, are not affected.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 882)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 883) 3. The format of the ``chromakey`` field in struct v4l2_window changed from
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 884) "host order RGB32" to a pixel value in the same format as the framebuffer.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 885) This may **break compatibility** with existing applications. Drivers
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 886) supporting the "host order RGB32" format are not known.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 887)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 888) V4L2 in Linux 2.6.24
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 889) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 890)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 891) 1. The pixel formats ``V4L2_PIX_FMT_PAL8``, ``V4L2_PIX_FMT_YUV444``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 892) ``V4L2_PIX_FMT_YUV555``, ``V4L2_PIX_FMT_YUV565`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 893) ``V4L2_PIX_FMT_YUV32`` were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 894)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 895) V4L2 in Linux 2.6.25
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 896) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 897)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 898) 1. The pixel formats :ref:`V4L2_PIX_FMT_Y16 <V4L2-PIX-FMT-Y16>` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 899) :ref:`V4L2_PIX_FMT_SBGGR16 <V4L2-PIX-FMT-SBGGR16>` were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 900)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 901) 2. New :ref:`controls <control>` ``V4L2_CID_POWER_LINE_FREQUENCY``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 902) ``V4L2_CID_HUE_AUTO``, ``V4L2_CID_WHITE_BALANCE_TEMPERATURE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 903) ``V4L2_CID_SHARPNESS`` and ``V4L2_CID_BACKLIGHT_COMPENSATION`` were
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 904) added. The controls ``V4L2_CID_BLACK_LEVEL``, ``V4L2_CID_WHITENESS``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 905) ``V4L2_CID_HCENTER`` and ``V4L2_CID_VCENTER`` were deprecated.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 906)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 907) 3. A :ref:`Camera controls class <camera-controls>` was added, with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 908) the new controls ``V4L2_CID_EXPOSURE_AUTO``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 909) ``V4L2_CID_EXPOSURE_ABSOLUTE``, ``V4L2_CID_EXPOSURE_AUTO_PRIORITY``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 910) ``V4L2_CID_PAN_RELATIVE``, ``V4L2_CID_TILT_RELATIVE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 911) ``V4L2_CID_PAN_RESET``, ``V4L2_CID_TILT_RESET``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 912) ``V4L2_CID_PAN_ABSOLUTE``, ``V4L2_CID_TILT_ABSOLUTE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 913) ``V4L2_CID_FOCUS_ABSOLUTE``, ``V4L2_CID_FOCUS_RELATIVE`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 914) ``V4L2_CID_FOCUS_AUTO``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 915)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 916) 4. The ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` ioctls, which
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 917) were superseded by the :ref:`extended controls <extended-controls>`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 918) interface in Linux 2.6.18, where finally removed from the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 919) ``videodev2.h`` header file.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 920)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 921) V4L2 in Linux 2.6.26
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 922) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 923)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 924) 1. The pixel formats ``V4L2_PIX_FMT_Y16`` and ``V4L2_PIX_FMT_SBGGR16``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 925) were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 926)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 927) 2. Added user controls ``V4L2_CID_CHROMA_AGC`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 928) ``V4L2_CID_COLOR_KILLER``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 929)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 930) V4L2 in Linux 2.6.27
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 931) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 932)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 933) 1. The :ref:`VIDIOC_S_HW_FREQ_SEEK` ioctl
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 934) and the ``V4L2_CAP_HW_FREQ_SEEK`` capability were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 935)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 936) 2. The pixel formats ``V4L2_PIX_FMT_YVYU``, ``V4L2_PIX_FMT_PCA501``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 937) ``V4L2_PIX_FMT_PCA505``, ``V4L2_PIX_FMT_PCA508``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 938) ``V4L2_PIX_FMT_PCA561``, ``V4L2_PIX_FMT_SGBRG8``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 939) ``V4L2_PIX_FMT_PAC207`` and ``V4L2_PIX_FMT_PJPG`` were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 940)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 941) V4L2 in Linux 2.6.28
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 942) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 943)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 944) 1. Added ``V4L2_MPEG_AUDIO_ENCODING_AAC`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 945) ``V4L2_MPEG_AUDIO_ENCODING_AC3`` MPEG audio encodings.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 946)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 947) 2. Added ``V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC`` MPEG video encoding.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 948)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 949) 3. The pixel formats ``V4L2_PIX_FMT_SGRBG10`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 950) ``V4L2_PIX_FMT_SGRBG10DPCM8`` were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 951)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 952) V4L2 in Linux 2.6.29
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 953) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 954)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 955) 1. The ``VIDIOC_G_CHIP_IDENT`` ioctl was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 956) ``VIDIOC_G_CHIP_IDENT_OLD`` and ``VIDIOC_DBG_G_CHIP_IDENT`` was
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 957) introduced in its place. The old struct ``v4l2_chip_ident`` was renamed to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 958) struct ``v4l2_chip_ident_old``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 959)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 960) 2. The pixel formats ``V4L2_PIX_FMT_VYUY``, ``V4L2_PIX_FMT_NV16`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 961) ``V4L2_PIX_FMT_NV61`` were added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 962)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 963) 3. Added camera controls ``V4L2_CID_ZOOM_ABSOLUTE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 964) ``V4L2_CID_ZOOM_RELATIVE``, ``V4L2_CID_ZOOM_CONTINUOUS`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 965) ``V4L2_CID_PRIVACY``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 966)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 967) V4L2 in Linux 2.6.30
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 968) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 969)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 970) 1. New control flag ``V4L2_CTRL_FLAG_WRITE_ONLY`` was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 971)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 972) 2. New control ``V4L2_CID_COLORFX`` was added.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 973)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 974) V4L2 in Linux 2.6.32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 975) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 976)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 977) 1. In order to be easier to compare a V4L2 API and a kernel version, now
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 978) V4L2 API is numbered using the Linux Kernel version numeration.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 979)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 980) 2. Finalized the RDS capture API. See :ref:`rds` for more information.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 981)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 982) 3. Added new capabilities for modulators and RDS encoders.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 983)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 984) 4. Add description for libv4l API.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 985)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 986) 5. Added support for string controls via new type
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 987) ``V4L2_CTRL_TYPE_STRING``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 988)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 989) 6. Added ``V4L2_CID_BAND_STOP_FILTER`` documentation.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 990)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 991) 7. Added FM Modulator (FM TX) Extended Control Class:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 992) ``V4L2_CTRL_CLASS_FM_TX`` and their Control IDs.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 993)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 994) 8. Added FM Receiver (FM RX) Extended Control Class:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 995) ``V4L2_CTRL_CLASS_FM_RX`` and their Control IDs.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 996)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 997) 9. Added Remote Controller chapter, describing the default Remote
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 998) Controller mapping for media devices.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 999)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1000) V4L2 in Linux 2.6.33
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1001) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1002)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1003) 1. Added support for Digital Video timings in order to support HDTV
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1004) receivers and transmitters.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1005)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1006) V4L2 in Linux 2.6.34
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1007) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1008)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1009) 1. Added ``V4L2_CID_IRIS_ABSOLUTE`` and ``V4L2_CID_IRIS_RELATIVE``
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1010) controls to the :ref:`Camera controls class <camera-controls>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1011)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1012) V4L2 in Linux 2.6.37
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1013) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1014)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1015) 1. Remove the vtx (videotext/teletext) API. This API was no longer used
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1016) and no hardware exists to verify the API. Nor were any userspace
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1017) applications found that used it. It was originally scheduled for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1018) removal in 2.6.35.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1019)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1020) V4L2 in Linux 2.6.39
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1021) ====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1022)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1023) 1. The old VIDIOC_*_OLD symbols and V4L1 support were removed.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1024)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1025) 2. Multi-planar API added. Does not affect the compatibility of current
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1026) drivers and applications. See :ref:`multi-planar API <planar-apis>`
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1027) for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1028)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1029) V4L2 in Linux 3.1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1030) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1031)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1032) 1. VIDIOC_QUERYCAP now returns a per-subsystem version instead of a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1033) per-driver one.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1034)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1035) Standardize an error code for invalid ioctl.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1036)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1037) Added V4L2_CTRL_TYPE_BITMASK.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1038)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1039) V4L2 in Linux 3.2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1040) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1041)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1042) 1. V4L2_CTRL_FLAG_VOLATILE was added to signal volatile controls to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1043) userspace.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1044)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1045) 2. Add selection API for extended control over cropping and composing.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1046) Does not affect the compatibility of current drivers and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1047) applications. See :ref:`selection API <selection-api>` for details.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1048)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1049) V4L2 in Linux 3.3
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1050) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1051)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1052) 1. Added ``V4L2_CID_ALPHA_COMPONENT`` control to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1053) :ref:`User controls class <control>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1054)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1055) 2. Added the device_caps field to struct v4l2_capabilities and added
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1056) the new V4L2_CAP_DEVICE_CAPS capability.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1057)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1058) V4L2 in Linux 3.4
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1059) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1060)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1061) 1. Added :ref:`JPEG compression control class <jpeg-controls>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1062)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1063) 2. Extended the DV Timings API:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1064) :ref:`VIDIOC_ENUM_DV_TIMINGS`,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1065) :ref:`VIDIOC_QUERY_DV_TIMINGS` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1066) :ref:`VIDIOC_DV_TIMINGS_CAP`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1067)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1068) V4L2 in Linux 3.5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1069) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1070)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1071) 1. Added integer menus, the new type will be
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1072) V4L2_CTRL_TYPE_INTEGER_MENU.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1073)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1074) 2. Added selection API for V4L2 subdev interface:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1075) :ref:`VIDIOC_SUBDEV_G_SELECTION` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1076) :ref:`VIDIOC_SUBDEV_S_SELECTION <VIDIOC_SUBDEV_G_SELECTION>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1077)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1078) 3. Added ``V4L2_COLORFX_ANTIQUE``, ``V4L2_COLORFX_ART_FREEZE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1079) ``V4L2_COLORFX_AQUA``, ``V4L2_COLORFX_SILHOUETTE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1080) ``V4L2_COLORFX_SOLARIZATION``, ``V4L2_COLORFX_VIVID`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1081) ``V4L2_COLORFX_ARBITRARY_CBCR`` menu items to the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1082) ``V4L2_CID_COLORFX`` control.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1083)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1084) 4. Added ``V4L2_CID_COLORFX_CBCR`` control.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1085)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1086) 5. Added camera controls ``V4L2_CID_AUTO_EXPOSURE_BIAS``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1087) ``V4L2_CID_AUTO_N_PRESET_WHITE_BALANCE``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1088) ``V4L2_CID_IMAGE_STABILIZATION``, ``V4L2_CID_ISO_SENSITIVITY``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1089) ``V4L2_CID_ISO_SENSITIVITY_AUTO``, ``V4L2_CID_EXPOSURE_METERING``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1090) ``V4L2_CID_SCENE_MODE``, ``V4L2_CID_3A_LOCK``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1091) ``V4L2_CID_AUTO_FOCUS_START``, ``V4L2_CID_AUTO_FOCUS_STOP``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1092) ``V4L2_CID_AUTO_FOCUS_STATUS`` and ``V4L2_CID_AUTO_FOCUS_RANGE``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1093)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1094) V4L2 in Linux 3.6
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1095) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1096)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1097) 1. Replaced ``input`` in struct v4l2_buffer by
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1098) ``reserved2`` and removed ``V4L2_BUF_FLAG_INPUT``.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1099)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1100) 2. Added V4L2_CAP_VIDEO_M2M and V4L2_CAP_VIDEO_M2M_MPLANE
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1101) capabilities.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1102)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1103) 3. Added support for frequency band enumerations:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1104) :ref:`VIDIOC_ENUM_FREQ_BANDS`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1105)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1106) V4L2 in Linux 3.9
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1107) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1108)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1109) 1. Added timestamp types to ``flags`` field in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1110) struct v4l2_buffer. See :ref:`buffer-flags`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1111)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1112) 2. Added ``V4L2_EVENT_CTRL_CH_RANGE`` control event changes flag. See
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1113) :ref:`ctrl-changes-flags`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1114)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1115) V4L2 in Linux 3.10
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1116) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1117)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1118) 1. Removed obsolete and unused DV_PRESET ioctls VIDIOC_G_DV_PRESET,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1119) VIDIOC_S_DV_PRESET, VIDIOC_QUERY_DV_PRESET and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1120) VIDIOC_ENUM_DV_PRESET. Remove the related v4l2_input/output
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1121) capability flags V4L2_IN_CAP_PRESETS and V4L2_OUT_CAP_PRESETS.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1122)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1123) 2. Added new debugging ioctl
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1124) :ref:`VIDIOC_DBG_G_CHIP_INFO`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1125)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1126) V4L2 in Linux 3.11
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1127) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1128)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1129) 1. Remove obsolete ``VIDIOC_DBG_G_CHIP_IDENT`` ioctl.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1130)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1131) V4L2 in Linux 3.14
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1132) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1133)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1134) 1. In struct v4l2_rect, the type of ``width`` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1135) ``height`` fields changed from _s32 to _u32.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1136)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1137) V4L2 in Linux 3.15
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1138) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1139)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1140) 1. Added Software Defined Radio (SDR) Interface.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1141)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1142) V4L2 in Linux 3.16
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1143) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1144)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1145) 1. Added event V4L2_EVENT_SOURCE_CHANGE.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1146)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1147) V4L2 in Linux 3.17
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1148) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1149)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1150) 1. Extended struct v4l2_pix_format. Added
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1151) format flags.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1152)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1153) 2. Added compound control types and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1154) :ref:`VIDIOC_QUERY_EXT_CTRL <VIDIOC_QUERYCTRL>`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1155)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1156) V4L2 in Linux 3.18
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1157) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1158)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1159) 1. Added ``V4L2_CID_PAN_SPEED`` and ``V4L2_CID_TILT_SPEED`` camera
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1160) controls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1161)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1162) V4L2 in Linux 3.19
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1163) ==================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1164)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1165) 1. Rewrote Colorspace chapter, added new enum v4l2_ycbcr_encoding
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1166) and enum v4l2_quantization fields to struct v4l2_pix_format,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1167) struct v4l2_pix_format_mplane and struct v4l2_mbus_framefmt.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1168)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1169) V4L2 in Linux 4.4
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1170) =================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1171)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1172) 1. Renamed ``V4L2_TUNER_ADC`` to ``V4L2_TUNER_SDR``. The use of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1173) ``V4L2_TUNER_ADC`` is deprecated now.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1174)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1175) 2. Added ``V4L2_CID_RF_TUNER_RF_GAIN`` RF Tuner control.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1176)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1177) 3. Added transmitter support for Software Defined Radio (SDR) Interface.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1178)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1179) .. _other:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1180)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1181) Relation of V4L2 to other Linux multimedia APIs
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1182) ===============================================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1183)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1184) .. _xvideo:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1185)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1186) X Video Extension
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1187) -----------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1188)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1189) The X Video Extension (abbreviated XVideo or just Xv) is an extension of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1190) the X Window system, implemented for example by the XFree86 project. Its
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1191) scope is similar to V4L2, an API to video capture and output devices for
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1192) X clients. Xv allows applications to display live video in a window,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1193) send window contents to a TV output, and capture or output still images
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1194) in XPixmaps [#f1]_. With their implementation XFree86 makes the extension
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1195) available across many operating systems and architectures.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1196)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1197) Because the driver is embedded into the X server Xv has a number of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1198) advantages over the V4L2 :ref:`video overlay interface <overlay>`. The
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1199) driver can easily determine the overlay target, i. e. visible graphics
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1200) memory or off-screen buffers for a destructive overlay. It can program
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1201) the RAMDAC for a non-destructive overlay, scaling or color-keying, or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1202) the clipping functions of the video capture hardware, always in sync
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1203) with drawing operations or windows moving or changing their stacking
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1204) order.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1205)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1206) To combine the advantages of Xv and V4L a special Xv driver exists in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1207) XFree86 and XOrg, just programming any overlay capable Video4Linux
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1208) device it finds. To enable it ``/etc/X11/XF86Config`` must contain these
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1209) lines:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1210)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1211) ::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1212)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1213) Section "Module"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1214) Load "v4l"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1215) EndSection
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1216)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1217) As of XFree86 4.2 this driver still supports only V4L ioctls, however it
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1218) should work just fine with all V4L2 devices through the V4L2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1219) backward-compatibility layer. Since V4L2 permits multiple opens it is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1220) possible (if supported by the V4L2 driver) to capture video while an X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1221) client requested video overlay. Restrictions of simultaneous capturing
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1222) and overlay are discussed in :ref:`overlay` apply.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1223)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1224) Only marginally related to V4L2, XFree86 extended Xv to support hardware
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1225) YUV to RGB conversion and scaling for faster video playback, and added
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1226) an interface to MPEG-2 decoding hardware. This API is useful to display
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1227) images captured with V4L2 devices.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1228)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1229) Digital Video
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1230) -------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1231)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1232) V4L2 does not support digital terrestrial, cable or satellite broadcast.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1233) A separate project aiming at digital receivers exists. You can find its
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1234) homepage at `https://linuxtv.org <https://linuxtv.org>`__. The Linux
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1235) DVB API has no connection to the V4L2 API except that drivers for hybrid
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1236) hardware may support both.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1237)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1238) Audio Interfaces
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1239) ----------------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1240)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1241) [to do - OSS/ALSA]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1242)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1243) .. _experimental:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1244)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1245) Experimental API Elements
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1246) =========================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1247)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1248) The following V4L2 API elements are currently experimental and may
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1249) change in the future.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1250)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1251) - :ref:`VIDIOC_DBG_G_REGISTER` and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1252) :ref:`VIDIOC_DBG_S_REGISTER <VIDIOC_DBG_G_REGISTER>` ioctls.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1253)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1254) - :ref:`VIDIOC_DBG_G_CHIP_INFO` ioctl.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1255)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1256) .. _obsolete:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1257)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1258) Obsolete API Elements
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1259) =====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1260)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1261) The following V4L2 API elements were superseded by new interfaces and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1262) should not be implemented in new drivers.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1263)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1264) - ``VIDIOC_G_MPEGCOMP`` and ``VIDIOC_S_MPEGCOMP`` ioctls. Use Extended
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1265) Controls, :ref:`extended-controls`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1266)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1267) - VIDIOC_G_DV_PRESET, VIDIOC_S_DV_PRESET,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1268) VIDIOC_ENUM_DV_PRESETS and VIDIOC_QUERY_DV_PRESET ioctls. Use
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1269) the DV Timings API (:ref:`dv-timings`).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1270)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1271) - ``VIDIOC_SUBDEV_G_CROP`` and ``VIDIOC_SUBDEV_S_CROP`` ioctls. Use
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1272) ``VIDIOC_SUBDEV_G_SELECTION`` and ``VIDIOC_SUBDEV_S_SELECTION``,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1273) :ref:`VIDIOC_SUBDEV_G_SELECTION`.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1274)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1275) .. [#f1]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1276) This is not implemented in XFree86.