0001 .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
0002 .. c:namespace:: V4L
0003
0004 .. _VIDIOC_ENUMAUDOUT:
0005
0006 ***********************
0007 ioctl VIDIOC_ENUMAUDOUT
0008 ***********************
0009
0010 Name
0011 ====
0012
0013 VIDIOC_ENUMAUDOUT - Enumerate audio outputs
0014
0015 Synopsis
0016 ========
0017
0018 .. c:macro:: VIDIOC_ENUMAUDOUT
0019
0020 ``int ioctl(int fd, VIDIOC_ENUMAUDOUT, struct v4l2_audioout *argp)``
0021
0022 Arguments
0023 =========
0024
0025 ``fd``
0026 File descriptor returned by :c:func:`open()`.
0027
0028 ``argp``
0029 Pointer to struct :c:type:`v4l2_audioout`.
0030
0031 Description
0032 ===========
0033
0034 To query the attributes of an audio output applications initialize the
0035 ``index`` field and zero out the ``reserved`` array of a struct
0036 :c:type:`v4l2_audioout` and call the ``VIDIOC_G_AUDOUT``
0037 ioctl with a pointer to this structure. Drivers fill the rest of the
0038 structure or return an ``EINVAL`` error code when the index is out of
0039 bounds. To enumerate all audio outputs applications shall begin at index
0040 zero, incrementing by one until the driver returns ``EINVAL``.
0041
0042 .. note::
0043
0044 Connectors on a TV card to loop back the received audio signal
0045 to a sound card are not audio outputs in this sense.
0046
0047 See :ref:`VIDIOC_G_AUDIOout <VIDIOC_G_AUDOUT>` for a description of struct
0048 :c:type:`v4l2_audioout`.
0049
0050 Return Value
0051 ============
0052
0053 On success 0 is returned, on error -1 and the ``errno`` variable is set
0054 appropriately. The generic error codes are described at the
0055 :ref:`Generic Error Codes <gen-errors>` chapter.
0056
0057 EINVAL
0058 The number of the audio output is out of bounds.