1 .. -*- coding: utf-8; mode: rst -*-
3 .. _VIDIOC_ENUM_DV_TIMINGS:
5 ***********************************************************
6 ioctl VIDIOC_ENUM_DV_TIMINGS, VIDIOC_SUBDEV_ENUM_DV_TIMINGS
7 ***********************************************************
12 VIDIOC_ENUM_DV_TIMINGS - VIDIOC_SUBDEV_ENUM_DV_TIMINGS - Enumerate supported Digital Video timings
18 .. cpp:function:: int ioctl( int fd, int request, struct v4l2_enum_dv_timings *argp )
25 File descriptor returned by :ref:`open() <func-open>`.
28 VIDIOC_ENUM_DV_TIMINGS, VIDIOC_SUBDEV_ENUM_DV_TIMINGS
36 While some DV receivers or transmitters support a wide range of timings,
37 others support only a limited number of timings. With this ioctl
38 applications can enumerate a list of known supported timings. Call
39 :ref:`VIDIOC_DV_TIMINGS_CAP` to check if it
40 also supports other standards or even custom timings that are not in
43 To query the available timings, applications initialize the ``index``
44 field, set the ``pad`` field to 0, zero the reserved array of struct
45 :ref:`v4l2_enum_dv_timings <v4l2-enum-dv-timings>` and call the
46 ``VIDIOC_ENUM_DV_TIMINGS`` ioctl on a video node with a pointer to this
47 structure. Drivers fill the rest of the structure or return an ``EINVAL``
48 error code when the index is out of bounds. To enumerate all supported
49 DV timings, applications shall begin at index zero, incrementing by one
50 until the driver returns ``EINVAL``.
52 .. note:: Drivers may enumerate a different set of DV timings after
53 switching the video input or output.
55 When implemented by the driver DV timings of subdevices can be queried
56 by calling the ``VIDIOC_SUBDEV_ENUM_DV_TIMINGS`` ioctl directly on a
57 subdevice node. The DV timings are specific to inputs (for DV receivers)
58 or outputs (for DV transmitters), applications must specify the desired
59 pad number in the struct
60 :ref:`v4l2_enum_dv_timings <v4l2-enum-dv-timings>` ``pad`` field.
61 Attempts to enumerate timings on a pad that doesn't support them will
62 return an ``EINVAL`` error code.
65 .. _v4l2-enum-dv-timings:
67 .. flat-table:: struct v4l2_enum_dv_timings
79 - Number of the DV timings, set by the application.
87 - Pad number as reported by the media controller API. This field is
88 only used when operating on a subdevice node. When operating on a
89 video node applications must set this field to zero.
97 - Reserved for future extensions. Drivers and applications must set
102 - struct :ref:`v4l2_dv_timings <v4l2-dv-timings>`
112 On success 0 is returned, on error -1 and the ``errno`` variable is set
113 appropriately. The generic error codes are described at the
114 :ref:`Generic Error Codes <gen-errors>` chapter.
117 The struct :ref:`v4l2_enum_dv_timings <v4l2-enum-dv-timings>`
118 ``index`` is out of bounds or the ``pad`` number is invalid.
121 Digital video presets are not supported for this input or output.