1 <refentry id="vidioc-g-output">
3 <refentrytitle>ioctl VIDIOC_G_OUTPUT, VIDIOC_S_OUTPUT</refentrytitle>
8 <refname>VIDIOC_G_OUTPUT</refname>
9 <refname>VIDIOC_S_OUTPUT</refname>
10 <refpurpose>Query or select the current video output</refpurpose>
16 <funcdef>int <function>ioctl</function></funcdef>
17 <paramdef>int <parameter>fd</parameter></paramdef>
18 <paramdef>int <parameter>request</parameter></paramdef>
19 <paramdef>int *<parameter>argp</parameter></paramdef>
25 <title>Arguments</title>
29 <term><parameter>fd</parameter></term>
35 <term><parameter>request</parameter></term>
37 <para>VIDIOC_G_OUTPUT, VIDIOC_S_OUTPUT</para>
41 <term><parameter>argp</parameter></term>
50 <title>Description</title>
52 <para>To query the current video output applications call the
53 <constant>VIDIOC_G_OUTPUT</constant> ioctl with a pointer to an integer
54 where the driver stores the number of the output, as in the
55 &v4l2-output; <structfield>index</structfield> field. This ioctl
56 will fail only when there are no video outputs, returning the
59 <para>To select a video output applications store the number of the
60 desired output in an integer and call the
61 <constant>VIDIOC_S_OUTPUT</constant> ioctl with a pointer to this integer.
62 Side effects are possible. For example outputs may support different
63 video standards, so the driver may implicitly switch the current
64 standard. It is good practice to select an output before querying or
65 negotiating any other parameters.</para>
67 <para>Information about video outputs is available using the
68 &VIDIOC-ENUMOUTPUT; ioctl.</para>
76 <term><errorcode>EINVAL</errorcode></term>
78 <para>The number of the video output is out of bounds, or
79 there are no video outputs at all.</para>