blob: 23fdf79f8cf366fbecb9e10b1fd2ad70b2905e21 [file] [log] [blame]
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03001 <section id="control">
2 <title>User Controls</title>
3
4 <para>Devices typically have a number of user-settable controls
5such as brightness, saturation and so on, which would be presented to
6the user on a graphical user interface. But, different devices
7will have different controls available, and furthermore, the range of
8possible values, and the default value will vary from device to
9device. The control ioctls provide the information and a mechanism to
10create a nice user interface for these controls that will work
11correctly with any device.</para>
12
13 <para>All controls are accessed using an ID value. V4L2 defines
14several IDs for specific purposes. Drivers can also implement their
15own custom controls using <constant>V4L2_CID_PRIVATE_BASE</constant>
16and higher values. The pre-defined control IDs have the prefix
17<constant>V4L2_CID_</constant>, and are listed in <xref
18linkend="control-id" />. The ID is used when querying the attributes of
19a control, and when getting or setting the current value.</para>
20
21 <para>Generally applications should present controls to the user
22without assumptions about their purpose. Each control comes with a
23name string the user is supposed to understand. When the purpose is
24non-intuitive the driver writer should provide a user manual, a user
25interface plug-in or a driver specific panel application. Predefined
26IDs were introduced to change a few controls programmatically, for
27example to mute a device during a channel switch.</para>
28
29 <para>Drivers may enumerate different controls after switching
30the current video input or output, tuner or modulator, or audio input
31or output. Different in the sense of other bounds, another default and
32current value, step size or other menu items. A control with a certain
33<emphasis>custom</emphasis> ID can also change name and
34type.<footnote>
35 <para>It will be more convenient for applications if drivers
36make use of the <constant>V4L2_CTRL_FLAG_DISABLED</constant> flag, but
37that was never required.</para>
38 </footnote> Control values are stored globally, they do not
39change when switching except to stay within the reported bounds. They
40also do not change &eg; when the device is opened or closed, when the
41tuner radio frequency is changed or generally never without
42application request. Since V4L2 specifies no event mechanism, panel
43applications intended to cooperate with other panel applications (be
44they built into a larger application, as a TV viewer) may need to
45regularly poll control values to update their user
46interface.<footnote>
47 <para>Applications could call an ioctl to request events.
48After another process called &VIDIOC-S-CTRL; or another ioctl changing
49shared properties the &func-select; function would indicate
50readability until any ioctl (querying the properties) is
51called.</para>
52 </footnote></para>
53
Sakari Ailus0f427212011-07-04 05:37:21 -030054 <para>
55 All controls use machine endianness.
56 </para>
57
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -030058 <table pgwide="1" frame="none" id="control-id">
59 <title>Control IDs</title>
60 <tgroup cols="3">
61 &cs-def;
62 <thead>
63 <row>
64 <entry>ID</entry>
65 <entry>Type</entry>
66 <entry>Description</entry>
67 </row>
68 </thead>
69 <tbody valign="top">
70 <row>
71 <entry><constant>V4L2_CID_BASE</constant></entry>
72 <entry></entry>
73 <entry>First predefined ID, equal to
74<constant>V4L2_CID_BRIGHTNESS</constant>.</entry>
75 </row>
76 <row>
77 <entry><constant>V4L2_CID_USER_BASE</constant></entry>
78 <entry></entry>
79 <entry>Synonym of <constant>V4L2_CID_BASE</constant>.</entry>
80 </row>
81 <row>
82 <entry><constant>V4L2_CID_BRIGHTNESS</constant></entry>
83 <entry>integer</entry>
84 <entry>Picture brightness, or more precisely, the black
85level.</entry>
86 </row>
87 <row>
88 <entry><constant>V4L2_CID_CONTRAST</constant></entry>
89 <entry>integer</entry>
90 <entry>Picture contrast or luma gain.</entry>
91 </row>
92 <row>
93 <entry><constant>V4L2_CID_SATURATION</constant></entry>
94 <entry>integer</entry>
95 <entry>Picture color saturation or chroma gain.</entry>
96 </row>
97 <row>
98 <entry><constant>V4L2_CID_HUE</constant></entry>
99 <entry>integer</entry>
100 <entry>Hue or color balance.</entry>
101 </row>
102 <row>
103 <entry><constant>V4L2_CID_AUDIO_VOLUME</constant></entry>
104 <entry>integer</entry>
105 <entry>Overall audio volume. Note some drivers also
106provide an OSS or ALSA mixer interface.</entry>
107 </row>
108 <row>
109 <entry><constant>V4L2_CID_AUDIO_BALANCE</constant></entry>
110 <entry>integer</entry>
111 <entry>Audio stereo balance. Minimum corresponds to all
112the way left, maximum to right.</entry>
113 </row>
114 <row>
115 <entry><constant>V4L2_CID_AUDIO_BASS</constant></entry>
116 <entry>integer</entry>
117 <entry>Audio bass adjustment.</entry>
118 </row>
119 <row>
120 <entry><constant>V4L2_CID_AUDIO_TREBLE</constant></entry>
121 <entry>integer</entry>
122 <entry>Audio treble adjustment.</entry>
123 </row>
124 <row>
125 <entry><constant>V4L2_CID_AUDIO_MUTE</constant></entry>
126 <entry>boolean</entry>
127 <entry>Mute audio, &ie; set the volume to zero, however
128without affecting <constant>V4L2_CID_AUDIO_VOLUME</constant>. Like
129ALSA drivers, V4L2 drivers must mute at load time to avoid excessive
130noise. Actually the entire device should be reset to a low power
131consumption state.</entry>
132 </row>
133 <row>
134 <entry><constant>V4L2_CID_AUDIO_LOUDNESS</constant></entry>
135 <entry>boolean</entry>
136 <entry>Loudness mode (bass boost).</entry>
137 </row>
138 <row>
139 <entry><constant>V4L2_CID_BLACK_LEVEL</constant></entry>
140 <entry>integer</entry>
141 <entry>Another name for brightness (not a synonym of
142<constant>V4L2_CID_BRIGHTNESS</constant>). This control is deprecated
143and should not be used in new drivers and applications.</entry>
144 </row>
145 <row>
146 <entry><constant>V4L2_CID_AUTO_WHITE_BALANCE</constant></entry>
147 <entry>boolean</entry>
148 <entry>Automatic white balance (cameras).</entry>
149 </row>
150 <row>
151 <entry><constant>V4L2_CID_DO_WHITE_BALANCE</constant></entry>
152 <entry>button</entry>
153 <entry>This is an action control. When set (the value is
154ignored), the device will do a white balance and then hold the current
155setting. Contrast this with the boolean
156<constant>V4L2_CID_AUTO_WHITE_BALANCE</constant>, which, when
157activated, keeps adjusting the white balance.</entry>
158 </row>
159 <row>
160 <entry><constant>V4L2_CID_RED_BALANCE</constant></entry>
161 <entry>integer</entry>
162 <entry>Red chroma balance.</entry>
163 </row>
164 <row>
165 <entry><constant>V4L2_CID_BLUE_BALANCE</constant></entry>
166 <entry>integer</entry>
167 <entry>Blue chroma balance.</entry>
168 </row>
169 <row>
170 <entry><constant>V4L2_CID_GAMMA</constant></entry>
171 <entry>integer</entry>
172 <entry>Gamma adjust.</entry>
173 </row>
174 <row>
175 <entry><constant>V4L2_CID_WHITENESS</constant></entry>
176 <entry>integer</entry>
177 <entry>Whiteness for grey-scale devices. This is a synonym
178for <constant>V4L2_CID_GAMMA</constant>. This control is deprecated
179and should not be used in new drivers and applications.</entry>
180 </row>
181 <row>
182 <entry><constant>V4L2_CID_EXPOSURE</constant></entry>
183 <entry>integer</entry>
184 <entry>Exposure (cameras). [Unit?]</entry>
185 </row>
186 <row>
187 <entry><constant>V4L2_CID_AUTOGAIN</constant></entry>
188 <entry>boolean</entry>
189 <entry>Automatic gain/exposure control.</entry>
190 </row>
191 <row>
192 <entry><constant>V4L2_CID_GAIN</constant></entry>
193 <entry>integer</entry>
194 <entry>Gain control.</entry>
195 </row>
196 <row>
197 <entry><constant>V4L2_CID_HFLIP</constant></entry>
198 <entry>boolean</entry>
199 <entry>Mirror the picture horizontally.</entry>
200 </row>
201 <row>
202 <entry><constant>V4L2_CID_VFLIP</constant></entry>
203 <entry>boolean</entry>
204 <entry>Mirror the picture vertically.</entry>
205 </row>
206 <row>
207 <entry><constant>V4L2_CID_HCENTER_DEPRECATED</constant> (formerly <constant>V4L2_CID_HCENTER</constant>)</entry>
208 <entry>integer</entry>
209 <entry>Horizontal image centering. This control is
210deprecated. New drivers and applications should use the <link
211linkend="camera-controls">Camera class controls</link>
212<constant>V4L2_CID_PAN_ABSOLUTE</constant>,
213<constant>V4L2_CID_PAN_RELATIVE</constant> and
214<constant>V4L2_CID_PAN_RESET</constant> instead.</entry>
215 </row>
216 <row>
217 <entry><constant>V4L2_CID_VCENTER_DEPRECATED</constant>
218 (formerly <constant>V4L2_CID_VCENTER</constant>)</entry>
219 <entry>integer</entry>
220 <entry>Vertical image centering. Centering is intended to
221<emphasis>physically</emphasis> adjust cameras. For image cropping see
222<xref linkend="crop" />, for clipping <xref linkend="overlay" />. This
223control is deprecated. New drivers and applications should use the
224<link linkend="camera-controls">Camera class controls</link>
225<constant>V4L2_CID_TILT_ABSOLUTE</constant>,
226<constant>V4L2_CID_TILT_RELATIVE</constant> and
227<constant>V4L2_CID_TILT_RESET</constant> instead.</entry>
228 </row>
229 <row id="v4l2-power-line-frequency">
230 <entry><constant>V4L2_CID_POWER_LINE_FREQUENCY</constant></entry>
231 <entry>enum</entry>
232 <entry>Enables a power line frequency filter to avoid
233flicker. Possible values for <constant>enum v4l2_power_line_frequency</constant> are:
234<constant>V4L2_CID_POWER_LINE_FREQUENCY_DISABLED</constant> (0),
235<constant>V4L2_CID_POWER_LINE_FREQUENCY_50HZ</constant> (1) and
236<constant>V4L2_CID_POWER_LINE_FREQUENCY_60HZ</constant> (2).</entry>
237 </row>
238 <row>
239 <entry><constant>V4L2_CID_HUE_AUTO</constant></entry>
240 <entry>boolean</entry>
241 <entry>Enables automatic hue control by the device. The
242effect of setting <constant>V4L2_CID_HUE</constant> while automatic
243hue control is enabled is undefined, drivers should ignore such
244request.</entry>
245 </row>
246 <row>
247 <entry><constant>V4L2_CID_WHITE_BALANCE_TEMPERATURE</constant></entry>
248 <entry>integer</entry>
249 <entry>This control specifies the white balance settings
250as a color temperature in Kelvin. A driver should have a minimum of
2512800 (incandescent) to 6500 (daylight). For more information about
252color temperature see <ulink
253url="http://en.wikipedia.org/wiki/Color_temperature">Wikipedia</ulink>.</entry>
254 </row>
255 <row>
256 <entry><constant>V4L2_CID_SHARPNESS</constant></entry>
257 <entry>integer</entry>
258 <entry>Adjusts the sharpness filters in a camera. The
259minimum value disables the filters, higher values give a sharper
260picture.</entry>
261 </row>
262 <row>
263 <entry><constant>V4L2_CID_BACKLIGHT_COMPENSATION</constant></entry>
264 <entry>integer</entry>
265 <entry>Adjusts the backlight compensation in a camera. The
266minimum value disables backlight compensation.</entry>
267 </row>
268 <row>
269 <entry><constant>V4L2_CID_CHROMA_AGC</constant></entry>
270 <entry>boolean</entry>
271 <entry>Chroma automatic gain control.</entry>
272 </row>
273 <row>
Devin Heitmueller7a01f6d2010-03-11 21:27:59 -0300274 <entry><constant>V4L2_CID_CHROMA_GAIN</constant></entry>
275 <entry>integer</entry>
276 <entry>Adjusts the Chroma gain control (for use when chroma AGC
277 is disabled).</entry>
278 </row>
279 <row>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300280 <entry><constant>V4L2_CID_COLOR_KILLER</constant></entry>
281 <entry>boolean</entry>
282 <entry>Enable the color killer (&ie; force a black &amp; white image in case of a weak video signal).</entry>
283 </row>
284 <row id="v4l2-colorfx">
285 <entry><constant>V4L2_CID_COLORFX</constant></entry>
286 <entry>enum</entry>
287 <entry>Selects a color effect. Possible values for
288<constant>enum v4l2_colorfx</constant> are:
289<constant>V4L2_COLORFX_NONE</constant> (0),
Xiaolin Zhang35e6aa92010-04-18 23:06:50 -0300290<constant>V4L2_COLORFX_BW</constant> (1),
291<constant>V4L2_COLORFX_SEPIA</constant> (2),
292<constant>V4L2_COLORFX_NEGATIVE</constant> (3),
293<constant>V4L2_COLORFX_EMBOSS</constant> (4),
294<constant>V4L2_COLORFX_SKETCH</constant> (5),
295<constant>V4L2_COLORFX_SKY_BLUE</constant> (6),
296<constant>V4L2_COLORFX_GRASS_GREEN</constant> (7),
297<constant>V4L2_COLORFX_SKIN_WHITEN</constant> (8) and
298<constant>V4L2_COLORFX_VIVID</constant> (9).</entry>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300299 </row>
300 <row>
Vaibhav Hiremathbd977802009-11-09 10:04:06 -0300301 <entry><constant>V4L2_CID_ROTATE</constant></entry>
302 <entry>integer</entry>
303 <entry>Rotates the image by specified angle. Common angles are 90,
304 270 and 180. Rotating the image to 90 and 270 will reverse the height
305 and width of the display window. It is necessary to set the new height and
306 width of the picture using the &VIDIOC-S-FMT; ioctl according to
307 the rotation angle selected.</entry>
308 </row>
309 <row>
310 <entry><constant>V4L2_CID_BG_COLOR</constant></entry>
311 <entry>integer</entry>
312 <entry>Sets the background color on the current output device.
313 Background color needs to be specified in the RGB24 format. The
314 supplied 32 bit value is interpreted as bits 0-7 Red color information,
315 bits 8-15 Green color information, bits 16-23 Blue color
316 information and bits 24-31 must be zero.</entry>
317 </row>
318 <row>
Jean-François Moine008d35f2010-09-13 07:04:49 -0300319 <entry><constant>V4L2_CID_ILLUMINATORS_1</constant>
320 <constant>V4L2_CID_ILLUMINATORS_2</constant></entry>
321 <entry>boolean</entry>
322 <entry>Switch on or off the illuminator 1 or 2 of the device
323 (usually a microscope).</entry>
324 </row>
325 <row>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300326 <entry><constant>V4L2_CID_LASTP1</constant></entry>
327 <entry></entry>
328 <entry>End of the predefined control IDs (currently
Jean-François Moine008d35f2010-09-13 07:04:49 -0300329<constant>V4L2_CID_ILLUMINATORS_2</constant> + 1).</entry>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300330 </row>
331 <row>
Kamil Debskie65e4f12011-06-14 10:31:04 -0300332 <entry><constant>V4L2_CID_MIN_BUFFERS_FOR_CAPTURE</constant></entry>
333 <entry>integer</entry>
334 <entry>This is a read-only control that can be read by the application
335and used as a hint to determine the number of CAPTURE buffers to pass to REQBUFS.
336The value is the minimum number of CAPTURE buffers that is necessary for hardware
337to work.</entry>
338 </row>
339 <row>
340 <entry><constant>V4L2_CID_MIN_BUFFERS_FOR_OUTPUT</constant></entry>
341 <entry>integer</entry>
342 <entry>This is a read-only control that can be read by the application
343and used as a hint to determine the number of OUTPUT buffers to pass to REQBUFS.
344The value is the minimum number of OUTPUT buffers that is necessary for hardware
345to work.</entry>
346 </row>
347 <row>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300348 <entry><constant>V4L2_CID_PRIVATE_BASE</constant></entry>
349 <entry></entry>
350 <entry>ID of the first custom (driver specific) control.
351Applications depending on particular custom controls should check the
352driver name and version, see <xref linkend="querycap" />.</entry>
353 </row>
354 </tbody>
355 </tgroup>
356 </table>
357
358 <para>Applications can enumerate the available controls with the
359&VIDIOC-QUERYCTRL; and &VIDIOC-QUERYMENU; ioctls, get and set a
360control value with the &VIDIOC-G-CTRL; and &VIDIOC-S-CTRL; ioctls.
361Drivers must implement <constant>VIDIOC_QUERYCTRL</constant>,
362<constant>VIDIOC_G_CTRL</constant> and
363<constant>VIDIOC_S_CTRL</constant> when the device has one or more
364controls, <constant>VIDIOC_QUERYMENU</constant> when it has one or
365more menu type controls.</para>
366
367 <example>
368 <title>Enumerating all controls</title>
369
370 <programlisting>
371&v4l2-queryctrl; queryctrl;
372&v4l2-querymenu; querymenu;
373
374static void
375enumerate_menu (void)
376{
377 printf (" Menu items:\n");
378
379 memset (&amp;querymenu, 0, sizeof (querymenu));
380 querymenu.id = queryctrl.id;
381
382 for (querymenu.index = queryctrl.minimum;
383 querymenu.index &lt;= queryctrl.maximum;
384 querymenu.index++) {
385 if (0 == ioctl (fd, &VIDIOC-QUERYMENU;, &amp;querymenu)) {
386 printf (" %s\n", querymenu.name);
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300387 }
388 }
389}
390
391memset (&amp;queryctrl, 0, sizeof (queryctrl));
392
393for (queryctrl.id = V4L2_CID_BASE;
394 queryctrl.id &lt; V4L2_CID_LASTP1;
395 queryctrl.id++) {
396 if (0 == ioctl (fd, &VIDIOC-QUERYCTRL;, &amp;queryctrl)) {
397 if (queryctrl.flags &amp; V4L2_CTRL_FLAG_DISABLED)
398 continue;
399
400 printf ("Control %s\n", queryctrl.name);
401
402 if (queryctrl.type == V4L2_CTRL_TYPE_MENU)
403 enumerate_menu ();
404 } else {
405 if (errno == EINVAL)
406 continue;
407
408 perror ("VIDIOC_QUERYCTRL");
409 exit (EXIT_FAILURE);
410 }
411}
412
413for (queryctrl.id = V4L2_CID_PRIVATE_BASE;;
414 queryctrl.id++) {
415 if (0 == ioctl (fd, &VIDIOC-QUERYCTRL;, &amp;queryctrl)) {
416 if (queryctrl.flags &amp; V4L2_CTRL_FLAG_DISABLED)
417 continue;
418
419 printf ("Control %s\n", queryctrl.name);
420
421 if (queryctrl.type == V4L2_CTRL_TYPE_MENU)
422 enumerate_menu ();
423 } else {
424 if (errno == EINVAL)
425 break;
426
427 perror ("VIDIOC_QUERYCTRL");
428 exit (EXIT_FAILURE);
429 }
430}
431</programlisting>
432 </example>
433
434 <example>
435 <title>Changing controls</title>
436
437 <programlisting>
438&v4l2-queryctrl; queryctrl;
439&v4l2-control; control;
440
441memset (&amp;queryctrl, 0, sizeof (queryctrl));
442queryctrl.id = V4L2_CID_BRIGHTNESS;
443
444if (-1 == ioctl (fd, &VIDIOC-QUERYCTRL;, &amp;queryctrl)) {
445 if (errno != EINVAL) {
446 perror ("VIDIOC_QUERYCTRL");
447 exit (EXIT_FAILURE);
448 } else {
449 printf ("V4L2_CID_BRIGHTNESS is not supported\n");
450 }
451} else if (queryctrl.flags &amp; V4L2_CTRL_FLAG_DISABLED) {
452 printf ("V4L2_CID_BRIGHTNESS is not supported\n");
453} else {
454 memset (&amp;control, 0, sizeof (control));
455 control.id = V4L2_CID_BRIGHTNESS;
456 control.value = queryctrl.default_value;
457
458 if (-1 == ioctl (fd, &VIDIOC-S-CTRL;, &amp;control)) {
459 perror ("VIDIOC_S_CTRL");
460 exit (EXIT_FAILURE);
461 }
462}
463
464memset (&amp;control, 0, sizeof (control));
465control.id = V4L2_CID_CONTRAST;
466
467if (0 == ioctl (fd, &VIDIOC-G-CTRL;, &amp;control)) {
468 control.value += 1;
469
470 /* The driver may clamp the value or return ERANGE, ignored here */
471
472 if (-1 == ioctl (fd, &VIDIOC-S-CTRL;, &amp;control)
473 &amp;&amp; errno != ERANGE) {
474 perror ("VIDIOC_S_CTRL");
475 exit (EXIT_FAILURE);
476 }
477/* Ignore if V4L2_CID_CONTRAST is unsupported */
478} else if (errno != EINVAL) {
479 perror ("VIDIOC_G_CTRL");
480 exit (EXIT_FAILURE);
481}
482
483control.id = V4L2_CID_AUDIO_MUTE;
484control.value = TRUE; /* silence */
485
486/* Errors ignored */
487ioctl (fd, VIDIOC_S_CTRL, &amp;control);
488</programlisting>
489 </example>
490 </section>
491
492 <section id="extended-controls">
493 <title>Extended Controls</title>
494
495 <section>
496 <title>Introduction</title>
497
498 <para>The control mechanism as originally designed was meant
499to be used for user settings (brightness, saturation, etc). However,
500it turned out to be a very useful model for implementing more
501complicated driver APIs where each driver implements only a subset of
502a larger API.</para>
503
504 <para>The MPEG encoding API was the driving force behind
505designing and implementing this extended control mechanism: the MPEG
506standard is quite large and the currently supported hardware MPEG
507encoders each only implement a subset of this standard. Further more,
508many parameters relating to how the video is encoded into an MPEG
509stream are specific to the MPEG encoding chip since the MPEG standard
510only defines the format of the resulting MPEG stream, not how the
511video is actually encoded into that format.</para>
512
513 <para>Unfortunately, the original control API lacked some
514features needed for these new uses and so it was extended into the
515(not terribly originally named) extended control API.</para>
516
517 <para>Even though the MPEG encoding API was the first effort
518to use the Extended Control API, nowadays there are also other classes
519of Extended Controls, such as Camera Controls and FM Transmitter Controls.
520The Extended Controls API as well as all Extended Controls classes are
521described in the following text.</para>
522 </section>
523
524 <section>
525 <title>The Extended Control API</title>
526
527 <para>Three new ioctls are available: &VIDIOC-G-EXT-CTRLS;,
528&VIDIOC-S-EXT-CTRLS; and &VIDIOC-TRY-EXT-CTRLS;. These ioctls act on
529arrays of controls (as opposed to the &VIDIOC-G-CTRL; and
530&VIDIOC-S-CTRL; ioctls that act on a single control). This is needed
531since it is often required to atomically change several controls at
532once.</para>
533
534 <para>Each of the new ioctls expects a pointer to a
535&v4l2-ext-controls;. This structure contains a pointer to the control
536array, a count of the number of controls in that array and a control
537class. Control classes are used to group similar controls into a
538single class. For example, control class
539<constant>V4L2_CTRL_CLASS_USER</constant> contains all user controls
540(&ie; all controls that can also be set using the old
541<constant>VIDIOC_S_CTRL</constant> ioctl). Control class
542<constant>V4L2_CTRL_CLASS_MPEG</constant> contains all controls
543relating to MPEG encoding, etc.</para>
544
545 <para>All controls in the control array must belong to the
546specified control class. An error is returned if this is not the
547case.</para>
548
549 <para>It is also possible to use an empty control array (count
550== 0) to check whether the specified control class is
551supported.</para>
552
553 <para>The control array is a &v4l2-ext-control; array. The
554<structname>v4l2_ext_control</structname> structure is very similar to
555&v4l2-control;, except for the fact that it also allows for 64-bit
556values and pointers to be passed.</para>
557
558 <para>It is important to realize that due to the flexibility of
559controls it is necessary to check whether the control you want to set
560actually is supported in the driver and what the valid range of values
561is. So use the &VIDIOC-QUERYCTRL; and &VIDIOC-QUERYMENU; ioctls to
562check this. Also note that it is possible that some of the menu
563indices in a control of type <constant>V4L2_CTRL_TYPE_MENU</constant>
564may not be supported (<constant>VIDIOC_QUERYMENU</constant> will
565return an error). A good example is the list of supported MPEG audio
566bitrates. Some drivers only support one or two bitrates, others
567support a wider range.</para>
Sakari Ailus0f427212011-07-04 05:37:21 -0300568
569 <para>
570 All controls use machine endianness.
571 </para>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300572 </section>
573
574 <section>
575 <title>Enumerating Extended Controls</title>
576
577 <para>The recommended way to enumerate over the extended
578controls is by using &VIDIOC-QUERYCTRL; in combination with the
579<constant>V4L2_CTRL_FLAG_NEXT_CTRL</constant> flag:</para>
580
581 <informalexample>
582 <programlisting>
583&v4l2-queryctrl; qctrl;
584
585qctrl.id = V4L2_CTRL_FLAG_NEXT_CTRL;
586while (0 == ioctl (fd, &VIDIOC-QUERYCTRL;, &amp;qctrl)) {
587 /* ... */
588 qctrl.id |= V4L2_CTRL_FLAG_NEXT_CTRL;
589}
590</programlisting>
591 </informalexample>
592
593 <para>The initial control ID is set to 0 ORed with the
594<constant>V4L2_CTRL_FLAG_NEXT_CTRL</constant> flag. The
595<constant>VIDIOC_QUERYCTRL</constant> ioctl will return the first
596control with a higher ID than the specified one. When no such controls
597are found an error is returned.</para>
598
599 <para>If you want to get all controls within a specific control
600class, then you can set the initial
601<structfield>qctrl.id</structfield> value to the control class and add
602an extra check to break out of the loop when a control of another
603control class is found:</para>
604
605 <informalexample>
606 <programlisting>
607qctrl.id = V4L2_CTRL_CLASS_MPEG | V4L2_CTRL_FLAG_NEXT_CTRL;
608while (0 == ioctl (fd, &VIDIOC-QUERYCTRL;, &amp;qctrl)) {
609 if (V4L2_CTRL_ID2CLASS (qctrl.id) != V4L2_CTRL_CLASS_MPEG)
610 break;
611 /* ... */
612 qctrl.id |= V4L2_CTRL_FLAG_NEXT_CTRL;
613 }
614</programlisting>
615 </informalexample>
616
617 <para>The 32-bit <structfield>qctrl.id</structfield> value is
618subdivided into three bit ranges: the top 4 bits are reserved for
619flags (&eg; <constant>V4L2_CTRL_FLAG_NEXT_CTRL</constant>) and are not
620actually part of the ID. The remaining 28 bits form the control ID, of
621which the most significant 12 bits define the control class and the
622least significant 16 bits identify the control within the control
623class. It is guaranteed that these last 16 bits are always non-zero
624for controls. The range of 0x1000 and up are reserved for
625driver-specific controls. The macro
626<constant>V4L2_CTRL_ID2CLASS(id)</constant> returns the control class
627ID based on a control ID.</para>
628
629 <para>If the driver does not support extended controls, then
630<constant>VIDIOC_QUERYCTRL</constant> will fail when used in
631combination with <constant>V4L2_CTRL_FLAG_NEXT_CTRL</constant>. In
632that case the old method of enumerating control should be used (see
6331.8). But if it is supported, then it is guaranteed to enumerate over
634all controls, including driver-private controls.</para>
635 </section>
636
637 <section>
638 <title>Creating Control Panels</title>
639
640 <para>It is possible to create control panels for a graphical
641user interface where the user can select the various controls.
642Basically you will have to iterate over all controls using the method
643described above. Each control class starts with a control of type
644<constant>V4L2_CTRL_TYPE_CTRL_CLASS</constant>.
645<constant>VIDIOC_QUERYCTRL</constant> will return the name of this
646control class which can be used as the title of a tab page within a
647control panel.</para>
648
649 <para>The flags field of &v4l2-queryctrl; also contains hints on
650the behavior of the control. See the &VIDIOC-QUERYCTRL; documentation
651for more details.</para>
652 </section>
653
654 <section id="mpeg-controls">
655 <title>MPEG Control Reference</title>
656
657 <para>Below all controls within the MPEG control class are
658described. First the generic controls, then controls specific for
659certain hardware.</para>
660
661 <section>
662 <title>Generic MPEG Controls</title>
663
664 <table pgwide="1" frame="none" id="mpeg-control-id">
665 <title>MPEG Control IDs</title>
666 <tgroup cols="4">
667 <colspec colname="c1" colwidth="1*" />
668 <colspec colname="c2" colwidth="6*" />
669 <colspec colname="c3" colwidth="2*" />
670 <colspec colname="c4" colwidth="6*" />
671 <spanspec namest="c1" nameend="c2" spanname="id" />
672 <spanspec namest="c2" nameend="c4" spanname="descr" />
673 <thead>
674 <row>
675 <entry spanname="id" align="left">ID</entry>
676 <entry align="left">Type</entry>
677 </row><row rowsep="1"><entry spanname="descr" align="left">Description</entry>
678 </row>
679 </thead>
680 <tbody valign="top">
681 <row><entry></entry></row>
682 <row>
683 <entry spanname="id"><constant>V4L2_CID_MPEG_CLASS</constant>&nbsp;</entry>
684 <entry>class</entry>
685 </row><row><entry spanname="descr">The MPEG class
686descriptor. Calling &VIDIOC-QUERYCTRL; for this control will return a
687description of this control class. This description can be used as the
688caption of a Tab page in a GUI, for example.</entry>
689 </row>
690 <row><entry></entry></row>
691 <row id="v4l2-mpeg-stream-type">
692 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_TYPE</constant>&nbsp;</entry>
693 <entry>enum&nbsp;v4l2_mpeg_stream_type</entry>
694 </row><row><entry spanname="descr">The MPEG-1, -2 or -4
695output stream type. One cannot assume anything here. Each hardware
696MPEG encoder tends to support different subsets of the available MPEG
Kamil Debski4fa64da2011-07-04 13:25:50 -0300697stream types. This control is specific to multiplexed MPEG streams.
698The currently defined stream types are:</entry>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300699 </row>
700 <row>
701 <entrytbl spanname="descr" cols="2">
702 <tbody valign="top">
703 <row>
704 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG2_PS</constant>&nbsp;</entry>
705 <entry>MPEG-2 program stream</entry>
706 </row>
707 <row>
708 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG2_TS</constant>&nbsp;</entry>
709 <entry>MPEG-2 transport stream</entry>
710 </row>
711 <row>
712 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG1_SS</constant>&nbsp;</entry>
713 <entry>MPEG-1 system stream</entry>
714 </row>
715 <row>
716 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG2_DVD</constant>&nbsp;</entry>
717 <entry>MPEG-2 DVD-compatible stream</entry>
718 </row>
719 <row>
720 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG1_VCD</constant>&nbsp;</entry>
721 <entry>MPEG-1 VCD-compatible stream</entry>
722 </row>
723 <row>
724 <entry><constant>V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD</constant>&nbsp;</entry>
725 <entry>MPEG-2 SVCD-compatible stream</entry>
726 </row>
727 </tbody>
728 </entrytbl>
729 </row>
730 <row><entry></entry></row>
731 <row>
732 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PID_PMT</constant>&nbsp;</entry>
733 <entry>integer</entry>
734 </row><row><entry spanname="descr">Program Map Table
735Packet ID for the MPEG transport stream (default 16)</entry>
736 </row>
737 <row><entry></entry></row>
738 <row>
739 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PID_AUDIO</constant>&nbsp;</entry>
740 <entry>integer</entry>
741 </row><row><entry spanname="descr">Audio Packet ID for
742the MPEG transport stream (default 256)</entry>
743 </row>
744 <row><entry></entry></row>
745 <row>
746 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PID_VIDEO</constant>&nbsp;</entry>
747 <entry>integer</entry>
748 </row><row><entry spanname="descr">Video Packet ID for
749the MPEG transport stream (default 260)</entry>
750 </row>
751 <row><entry></entry></row>
752 <row>
753 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PID_PCR</constant>&nbsp;</entry>
754 <entry>integer</entry>
755 </row><row><entry spanname="descr">Packet ID for the
756MPEG transport stream carrying PCR fields (default 259)</entry>
757 </row>
758 <row><entry></entry></row>
759 <row>
760 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PES_ID_AUDIO</constant>&nbsp;</entry>
761 <entry>integer</entry>
762 </row><row><entry spanname="descr">Audio ID for MPEG
763PES</entry>
764 </row>
765 <row><entry></entry></row>
766 <row>
767 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_PES_ID_VIDEO</constant>&nbsp;</entry>
768 <entry>integer</entry>
769 </row><row><entry spanname="descr">Video ID for MPEG
770PES</entry>
771 </row>
772 <row><entry></entry></row>
773 <row id="v4l2-mpeg-stream-vbi-fmt">
774 <entry spanname="id"><constant>V4L2_CID_MPEG_STREAM_VBI_FMT</constant>&nbsp;</entry>
775 <entry>enum&nbsp;v4l2_mpeg_stream_vbi_fmt</entry>
776 </row><row><entry spanname="descr">Some cards can embed
777VBI data (&eg; Closed Caption, Teletext) into the MPEG stream. This
778control selects whether VBI data should be embedded, and if so, what
779embedding method should be used. The list of possible VBI formats
780depends on the driver. The currently defined VBI format types
781are:</entry>
782 </row>
783 <row>
784 <entrytbl spanname="descr" cols="2">
785 <tbody valign="top">
786 <row>
787 <entry><constant>V4L2_MPEG_STREAM_VBI_FMT_NONE</constant>&nbsp;</entry>
788 <entry>No VBI in the MPEG stream</entry>
789 </row>
790 <row>
791 <entry><constant>V4L2_MPEG_STREAM_VBI_FMT_IVTV</constant>&nbsp;</entry>
792 <entry>VBI in private packets, IVTV format (documented
793in the kernel sources in the file <filename>Documentation/video4linux/cx2341x/README.vbi</filename>)</entry>
794 </row>
795 </tbody>
796 </entrytbl>
797 </row>
798 <row><entry></entry></row>
799 <row id="v4l2-mpeg-audio-sampling-freq">
800 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ</constant>&nbsp;</entry>
801 <entry>enum&nbsp;v4l2_mpeg_audio_sampling_freq</entry>
802 </row><row><entry spanname="descr">MPEG Audio sampling
803frequency. Possible values are:</entry>
804 </row>
805 <row>
806 <entrytbl spanname="descr" cols="2">
807 <tbody valign="top">
808 <row>
809 <entry><constant>V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100</constant>&nbsp;</entry>
810 <entry>44.1 kHz</entry>
811 </row>
812 <row>
813 <entry><constant>V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000</constant>&nbsp;</entry>
814 <entry>48 kHz</entry>
815 </row>
816 <row>
817 <entry><constant>V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000</constant>&nbsp;</entry>
818 <entry>32 kHz</entry>
819 </row>
820 </tbody>
821 </entrytbl>
822 </row>
823 <row><entry></entry></row>
824 <row id="v4l2-mpeg-audio-encoding">
825 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_ENCODING</constant>&nbsp;</entry>
826 <entry>enum&nbsp;v4l2_mpeg_audio_encoding</entry>
827 </row><row><entry spanname="descr">MPEG Audio encoding.
Kamil Debski4fa64da2011-07-04 13:25:50 -0300828This control is specific to multiplexed MPEG streams.
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -0300829Possible values are:</entry>
830 </row>
831 <row>
832 <entrytbl spanname="descr" cols="2">
833 <tbody valign="top">
834 <row>
835 <entry><constant>V4L2_MPEG_AUDIO_ENCODING_LAYER_1</constant>&nbsp;</entry>
836 <entry>MPEG-1/2 Layer I encoding</entry>
837 </row>
838 <row>
839 <entry><constant>V4L2_MPEG_AUDIO_ENCODING_LAYER_2</constant>&nbsp;</entry>
840 <entry>MPEG-1/2 Layer II encoding</entry>
841 </row>
842 <row>
843 <entry><constant>V4L2_MPEG_AUDIO_ENCODING_LAYER_3</constant>&nbsp;</entry>
844 <entry>MPEG-1/2 Layer III encoding</entry>
845 </row>
846 <row>
847 <entry><constant>V4L2_MPEG_AUDIO_ENCODING_AAC</constant>&nbsp;</entry>
848 <entry>MPEG-2/4 AAC (Advanced Audio Coding)</entry>
849 </row>
850 <row>
851 <entry><constant>V4L2_MPEG_AUDIO_ENCODING_AC3</constant>&nbsp;</entry>
852 <entry>AC-3 aka ATSC A/52 encoding</entry>
853 </row>
854 </tbody>
855 </entrytbl>
856 </row>
857 <row><entry></entry></row>
858 <row id="v4l2-mpeg-audio-l1-bitrate">
859 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_L1_BITRATE</constant>&nbsp;</entry>
860 <entry>enum&nbsp;v4l2_mpeg_audio_l1_bitrate</entry>
861 </row><row><entry spanname="descr">MPEG-1/2 Layer I bitrate.
862Possible values are:</entry>
863 </row>
864 <row>
865 <entrytbl spanname="descr" cols="2">
866 <tbody valign="top">
867 <row>
868 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_32K</constant>&nbsp;</entry>
869 <entry>32 kbit/s</entry></row>
870 <row>
871 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_64K</constant>&nbsp;</entry>
872 <entry>64 kbit/s</entry>
873 </row>
874 <row>
875 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_96K</constant>&nbsp;</entry>
876 <entry>96 kbit/s</entry>
877 </row>
878 <row>
879 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_128K</constant>&nbsp;</entry>
880 <entry>128 kbit/s</entry>
881 </row>
882 <row>
883 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_160K</constant>&nbsp;</entry>
884 <entry>160 kbit/s</entry>
885 </row>
886 <row>
887 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_192K</constant>&nbsp;</entry>
888 <entry>192 kbit/s</entry>
889 </row>
890 <row>
891 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_224K</constant>&nbsp;</entry>
892 <entry>224 kbit/s</entry>
893 </row>
894 <row>
895 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_256K</constant>&nbsp;</entry>
896 <entry>256 kbit/s</entry>
897 </row>
898 <row>
899 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_288K</constant>&nbsp;</entry>
900 <entry>288 kbit/s</entry>
901 </row>
902 <row>
903 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_320K</constant>&nbsp;</entry>
904 <entry>320 kbit/s</entry>
905 </row>
906 <row>
907 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_352K</constant>&nbsp;</entry>
908 <entry>352 kbit/s</entry>
909 </row>
910 <row>
911 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_384K</constant>&nbsp;</entry>
912 <entry>384 kbit/s</entry>
913 </row>
914 <row>
915 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_416K</constant>&nbsp;</entry>
916 <entry>416 kbit/s</entry>
917 </row>
918 <row>
919 <entry><constant>V4L2_MPEG_AUDIO_L1_BITRATE_448K</constant>&nbsp;</entry>
920 <entry>448 kbit/s</entry>
921 </row>
922 </tbody>
923 </entrytbl>
924 </row>
925 <row><entry></entry></row>
926 <row id="v4l2-mpeg-audio-l2-bitrate">
927 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_L2_BITRATE</constant>&nbsp;</entry>
928 <entry>enum&nbsp;v4l2_mpeg_audio_l2_bitrate</entry>
929 </row><row><entry spanname="descr">MPEG-1/2 Layer II bitrate.
930Possible values are:</entry>
931 </row>
932 <row>
933 <entrytbl spanname="descr" cols="2">
934 <tbody valign="top">
935 <row>
936 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_32K</constant>&nbsp;</entry>
937 <entry>32 kbit/s</entry>
938 </row>
939 <row>
940 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_48K</constant>&nbsp;</entry>
941 <entry>48 kbit/s</entry>
942 </row>
943 <row>
944 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_56K</constant>&nbsp;</entry>
945 <entry>56 kbit/s</entry>
946 </row>
947 <row>
948 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_64K</constant>&nbsp;</entry>
949 <entry>64 kbit/s</entry>
950 </row>
951 <row>
952 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_80K</constant>&nbsp;</entry>
953 <entry>80 kbit/s</entry>
954 </row>
955 <row>
956 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_96K</constant>&nbsp;</entry>
957 <entry>96 kbit/s</entry>
958 </row>
959 <row>
960 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_112K</constant>&nbsp;</entry>
961 <entry>112 kbit/s</entry>
962 </row>
963 <row>
964 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_128K</constant>&nbsp;</entry>
965 <entry>128 kbit/s</entry>
966 </row>
967 <row>
968 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_160K</constant>&nbsp;</entry>
969 <entry>160 kbit/s</entry>
970 </row>
971 <row>
972 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_192K</constant>&nbsp;</entry>
973 <entry>192 kbit/s</entry>
974 </row>
975 <row>
976 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_224K</constant>&nbsp;</entry>
977 <entry>224 kbit/s</entry>
978 </row>
979 <row>
980 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_256K</constant>&nbsp;</entry>
981 <entry>256 kbit/s</entry>
982 </row>
983 <row>
984 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_320K</constant>&nbsp;</entry>
985 <entry>320 kbit/s</entry>
986 </row>
987 <row>
988 <entry><constant>V4L2_MPEG_AUDIO_L2_BITRATE_384K</constant>&nbsp;</entry>
989 <entry>384 kbit/s</entry>
990 </row>
991 </tbody>
992 </entrytbl>
993 </row>
994 <row><entry></entry></row>
995 <row id="v4l2-mpeg-audio-l3-bitrate">
996 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_L3_BITRATE</constant>&nbsp;</entry>
997 <entry>enum&nbsp;v4l2_mpeg_audio_l3_bitrate</entry>
998 </row><row><entry spanname="descr">MPEG-1/2 Layer III bitrate.
999Possible values are:</entry>
1000 </row>
1001 <row>
1002 <entrytbl spanname="descr" cols="2">
1003 <tbody valign="top">
1004 <row>
1005 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_32K</constant>&nbsp;</entry>
1006 <entry>32 kbit/s</entry>
1007 </row>
1008 <row>
1009 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_40K</constant>&nbsp;</entry>
1010 <entry>40 kbit/s</entry>
1011 </row>
1012 <row>
1013 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_48K</constant>&nbsp;</entry>
1014 <entry>48 kbit/s</entry>
1015 </row>
1016 <row>
1017 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_56K</constant>&nbsp;</entry>
1018 <entry>56 kbit/s</entry>
1019 </row>
1020 <row>
1021 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_64K</constant>&nbsp;</entry>
1022 <entry>64 kbit/s</entry>
1023 </row>
1024 <row>
1025 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_80K</constant>&nbsp;</entry>
1026 <entry>80 kbit/s</entry>
1027 </row>
1028 <row>
1029 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_96K</constant>&nbsp;</entry>
1030 <entry>96 kbit/s</entry>
1031 </row>
1032 <row>
1033 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_112K</constant>&nbsp;</entry>
1034 <entry>112 kbit/s</entry>
1035 </row>
1036 <row>
1037 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_128K</constant>&nbsp;</entry>
1038 <entry>128 kbit/s</entry>
1039 </row>
1040 <row>
1041 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_160K</constant>&nbsp;</entry>
1042 <entry>160 kbit/s</entry>
1043 </row>
1044 <row>
1045 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_192K</constant>&nbsp;</entry>
1046 <entry>192 kbit/s</entry>
1047 </row>
1048 <row>
1049 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_224K</constant>&nbsp;</entry>
1050 <entry>224 kbit/s</entry>
1051 </row>
1052 <row>
1053 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_256K</constant>&nbsp;</entry>
1054 <entry>256 kbit/s</entry>
1055 </row>
1056 <row>
1057 <entry><constant>V4L2_MPEG_AUDIO_L3_BITRATE_320K</constant>&nbsp;</entry>
1058 <entry>320 kbit/s</entry>
1059 </row>
1060 </tbody>
1061 </entrytbl>
1062 </row>
1063 <row><entry></entry></row>
1064 <row>
1065 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_AAC_BITRATE</constant>&nbsp;</entry>
1066 <entry>integer</entry>
1067 </row><row><entry spanname="descr">AAC bitrate in bits per second.</entry>
1068 </row>
1069 <row><entry></entry></row>
1070 <row id="v4l2-mpeg-audio-ac3-bitrate">
1071 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_AC3_BITRATE</constant>&nbsp;</entry>
1072 <entry>enum&nbsp;v4l2_mpeg_audio_ac3_bitrate</entry>
1073 </row><row><entry spanname="descr">AC-3 bitrate.
1074Possible values are:</entry>
1075 </row>
1076 <row>
1077 <entrytbl spanname="descr" cols="2">
1078 <tbody valign="top">
1079 <row>
1080 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_32K</constant>&nbsp;</entry>
1081 <entry>32 kbit/s</entry>
1082 </row>
1083 <row>
1084 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_40K</constant>&nbsp;</entry>
1085 <entry>40 kbit/s</entry>
1086 </row>
1087 <row>
1088 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_48K</constant>&nbsp;</entry>
1089 <entry>48 kbit/s</entry>
1090 </row>
1091 <row>
1092 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_56K</constant>&nbsp;</entry>
1093 <entry>56 kbit/s</entry>
1094 </row>
1095 <row>
1096 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_64K</constant>&nbsp;</entry>
1097 <entry>64 kbit/s</entry>
1098 </row>
1099 <row>
1100 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_80K</constant>&nbsp;</entry>
1101 <entry>80 kbit/s</entry>
1102 </row>
1103 <row>
1104 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_96K</constant>&nbsp;</entry>
1105 <entry>96 kbit/s</entry>
1106 </row>
1107 <row>
1108 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_112K</constant>&nbsp;</entry>
1109 <entry>112 kbit/s</entry>
1110 </row>
1111 <row>
1112 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_128K</constant>&nbsp;</entry>
1113 <entry>128 kbit/s</entry>
1114 </row>
1115 <row>
1116 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_160K</constant>&nbsp;</entry>
1117 <entry>160 kbit/s</entry>
1118 </row>
1119 <row>
1120 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_192K</constant>&nbsp;</entry>
1121 <entry>192 kbit/s</entry>
1122 </row>
1123 <row>
1124 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_224K</constant>&nbsp;</entry>
1125 <entry>224 kbit/s</entry>
1126 </row>
1127 <row>
1128 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_256K</constant>&nbsp;</entry>
1129 <entry>256 kbit/s</entry>
1130 </row>
1131 <row>
1132 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_320K</constant>&nbsp;</entry>
1133 <entry>320 kbit/s</entry>
1134 </row>
1135 <row>
1136 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_384K</constant>&nbsp;</entry>
1137 <entry>384 kbit/s</entry>
1138 </row>
1139 <row>
1140 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_448K</constant>&nbsp;</entry>
1141 <entry>448 kbit/s</entry>
1142 </row>
1143 <row>
1144 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_512K</constant>&nbsp;</entry>
1145 <entry>512 kbit/s</entry>
1146 </row>
1147 <row>
1148 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_576K</constant>&nbsp;</entry>
1149 <entry>576 kbit/s</entry>
1150 </row>
1151 <row>
1152 <entry><constant>V4L2_MPEG_AUDIO_AC3_BITRATE_640K</constant>&nbsp;</entry>
1153 <entry>640 kbit/s</entry>
1154 </row>
1155 </tbody>
1156 </entrytbl>
1157 </row>
1158 <row><entry></entry></row>
1159 <row id="v4l2-mpeg-audio-mode">
1160 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_MODE</constant>&nbsp;</entry>
1161 <entry>enum&nbsp;v4l2_mpeg_audio_mode</entry>
1162 </row><row><entry spanname="descr">MPEG Audio mode.
1163Possible values are:</entry>
1164 </row>
1165 <row>
1166 <entrytbl spanname="descr" cols="2">
1167 <tbody valign="top">
1168 <row>
1169 <entry><constant>V4L2_MPEG_AUDIO_MODE_STEREO</constant>&nbsp;</entry>
1170 <entry>Stereo</entry>
1171 </row>
1172 <row>
1173 <entry><constant>V4L2_MPEG_AUDIO_MODE_JOINT_STEREO</constant>&nbsp;</entry>
1174 <entry>Joint Stereo</entry>
1175 </row>
1176 <row>
1177 <entry><constant>V4L2_MPEG_AUDIO_MODE_DUAL</constant>&nbsp;</entry>
1178 <entry>Bilingual</entry>
1179 </row>
1180 <row>
1181 <entry><constant>V4L2_MPEG_AUDIO_MODE_MONO</constant>&nbsp;</entry>
1182 <entry>Mono</entry>
1183 </row>
1184 </tbody>
1185 </entrytbl>
1186 </row>
1187 <row><entry></entry></row>
1188 <row id="v4l2-mpeg-audio-mode-extension">
1189 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_MODE_EXTENSION</constant>&nbsp;</entry>
1190 <entry>enum&nbsp;v4l2_mpeg_audio_mode_extension</entry>
1191 </row><row><entry spanname="descr">Joint Stereo
1192audio mode extension. In Layer I and II they indicate which subbands
1193are in intensity stereo. All other subbands are coded in stereo. Layer
1194III is not (yet) supported. Possible values
1195are:</entry>
1196 </row>
1197 <row>
1198 <entrytbl spanname="descr" cols="2">
1199 <tbody valign="top">
1200 <row>
1201 <entry><constant>V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4</constant>&nbsp;</entry>
1202 <entry>Subbands 4-31 in intensity stereo</entry>
1203 </row>
1204 <row>
1205 <entry><constant>V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8</constant>&nbsp;</entry>
1206 <entry>Subbands 8-31 in intensity stereo</entry>
1207 </row>
1208 <row>
1209 <entry><constant>V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12</constant>&nbsp;</entry>
1210 <entry>Subbands 12-31 in intensity stereo</entry>
1211 </row>
1212 <row>
1213 <entry><constant>V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16</constant>&nbsp;</entry>
1214 <entry>Subbands 16-31 in intensity stereo</entry>
1215 </row>
1216 </tbody>
1217 </entrytbl>
1218 </row>
1219 <row><entry></entry></row>
1220 <row id="v4l2-mpeg-audio-emphasis">
1221 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_EMPHASIS</constant>&nbsp;</entry>
1222 <entry>enum&nbsp;v4l2_mpeg_audio_emphasis</entry>
1223 </row><row><entry spanname="descr">Audio Emphasis.
1224Possible values are:</entry>
1225 </row>
1226 <row>
1227 <entrytbl spanname="descr" cols="2">
1228 <tbody valign="top">
1229 <row>
1230 <entry><constant>V4L2_MPEG_AUDIO_EMPHASIS_NONE</constant>&nbsp;</entry>
1231 <entry>None</entry>
1232 </row>
1233 <row>
1234 <entry><constant>V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS</constant>&nbsp;</entry>
1235 <entry>50/15 microsecond emphasis</entry>
1236 </row>
1237 <row>
1238 <entry><constant>V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17</constant>&nbsp;</entry>
1239 <entry>CCITT J.17</entry>
1240 </row>
1241 </tbody>
1242 </entrytbl>
1243 </row>
1244 <row><entry></entry></row>
1245 <row id="v4l2-mpeg-audio-crc">
1246 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_CRC</constant>&nbsp;</entry>
1247 <entry>enum&nbsp;v4l2_mpeg_audio_crc</entry>
1248 </row><row><entry spanname="descr">CRC method. Possible
1249values are:</entry>
1250 </row>
1251 <row>
1252 <entrytbl spanname="descr" cols="2">
1253 <tbody valign="top">
1254 <row>
1255 <entry><constant>V4L2_MPEG_AUDIO_CRC_NONE</constant>&nbsp;</entry>
1256 <entry>None</entry>
1257 </row>
1258 <row>
1259 <entry><constant>V4L2_MPEG_AUDIO_CRC_CRC16</constant>&nbsp;</entry>
1260 <entry>16 bit parity check</entry>
1261 </row>
1262 </tbody>
1263 </entrytbl>
1264 </row>
1265 <row><entry></entry></row>
1266 <row>
1267 <entry spanname="id"><constant>V4L2_CID_MPEG_AUDIO_MUTE</constant>&nbsp;</entry>
1268 <entry>boolean</entry>
1269 </row><row><entry spanname="descr">Mutes the audio when
1270capturing. This is not done by muting audio hardware, which can still
1271produce a slight hiss, but in the encoder itself, guaranteeing a fixed
Lucas De Marchi25985ed2011-03-30 22:57:33 -03001272and reproducible audio bitstream. 0 = unmuted, 1 = muted.</entry>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03001273 </row>
1274 <row><entry></entry></row>
1275 <row id="v4l2-mpeg-video-encoding">
1276 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_ENCODING</constant>&nbsp;</entry>
1277 <entry>enum&nbsp;v4l2_mpeg_video_encoding</entry>
1278 </row><row><entry spanname="descr">MPEG Video encoding
Kamil Debski4fa64da2011-07-04 13:25:50 -03001279method. This control is specific to multiplexed MPEG streams.
1280Possible values are:</entry>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03001281 </row>
1282 <row>
1283 <entrytbl spanname="descr" cols="2">
1284 <tbody valign="top">
1285 <row>
1286 <entry><constant>V4L2_MPEG_VIDEO_ENCODING_MPEG_1</constant>&nbsp;</entry>
1287 <entry>MPEG-1 Video encoding</entry>
1288 </row>
1289 <row>
1290 <entry><constant>V4L2_MPEG_VIDEO_ENCODING_MPEG_2</constant>&nbsp;</entry>
1291 <entry>MPEG-2 Video encoding</entry>
1292 </row>
1293 <row>
1294 <entry><constant>V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC</constant>&nbsp;</entry>
1295 <entry>MPEG-4 AVC (H.264) Video encoding</entry>
1296 </row>
1297 </tbody>
1298 </entrytbl>
1299 </row>
1300 <row><entry></entry></row>
1301 <row id="v4l2-mpeg-video-aspect">
1302 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_ASPECT</constant>&nbsp;</entry>
1303 <entry>enum&nbsp;v4l2_mpeg_video_aspect</entry>
1304 </row><row><entry spanname="descr">Video aspect.
1305Possible values are:</entry>
1306 </row>
1307 <row>
1308 <entrytbl spanname="descr" cols="2">
1309 <tbody valign="top">
1310 <row>
1311 <entry><constant>V4L2_MPEG_VIDEO_ASPECT_1x1</constant>&nbsp;</entry>
1312 </row>
1313 <row>
1314 <entry><constant>V4L2_MPEG_VIDEO_ASPECT_4x3</constant>&nbsp;</entry>
1315 </row>
1316 <row>
1317 <entry><constant>V4L2_MPEG_VIDEO_ASPECT_16x9</constant>&nbsp;</entry>
1318 </row>
1319 <row>
1320 <entry><constant>V4L2_MPEG_VIDEO_ASPECT_221x100</constant>&nbsp;</entry>
1321 </row>
1322 </tbody>
1323 </entrytbl>
1324 </row>
1325 <row><entry></entry></row>
1326 <row>
1327 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_B_FRAMES</constant>&nbsp;</entry>
1328 <entry>integer</entry>
1329 </row><row><entry spanname="descr">Number of B-Frames
1330(default 2)</entry>
1331 </row>
1332 <row><entry></entry></row>
1333 <row>
1334 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_GOP_SIZE</constant>&nbsp;</entry>
1335 <entry>integer</entry>
1336 </row><row><entry spanname="descr">GOP size (default
133712)</entry>
1338 </row>
1339 <row><entry></entry></row>
1340 <row>
1341 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_GOP_CLOSURE</constant>&nbsp;</entry>
1342 <entry>boolean</entry>
1343 </row><row><entry spanname="descr">GOP closure (default
13441)</entry>
1345 </row>
1346 <row><entry></entry></row>
1347 <row>
1348 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_PULLDOWN</constant>&nbsp;</entry>
1349 <entry>boolean</entry>
1350 </row><row><entry spanname="descr">Enable 3:2 pulldown
1351(default 0)</entry>
1352 </row>
1353 <row><entry></entry></row>
1354 <row id="v4l2-mpeg-video-bitrate-mode">
1355 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_BITRATE_MODE</constant>&nbsp;</entry>
1356 <entry>enum&nbsp;v4l2_mpeg_video_bitrate_mode</entry>
1357 </row><row><entry spanname="descr">Video bitrate mode.
1358Possible values are:</entry>
1359 </row>
1360 <row>
1361 <entrytbl spanname="descr" cols="2">
1362 <tbody valign="top">
1363 <row>
1364 <entry><constant>V4L2_MPEG_VIDEO_BITRATE_MODE_VBR</constant>&nbsp;</entry>
1365 <entry>Variable bitrate</entry>
1366 </row>
1367 <row>
1368 <entry><constant>V4L2_MPEG_VIDEO_BITRATE_MODE_CBR</constant>&nbsp;</entry>
1369 <entry>Constant bitrate</entry>
1370 </row>
1371 </tbody>
1372 </entrytbl>
1373 </row>
1374 <row><entry></entry></row>
1375 <row>
1376 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_BITRATE</constant>&nbsp;</entry>
1377 <entry>integer</entry>
1378 </row><row><entry spanname="descr">Video bitrate in bits
1379per second.</entry>
1380 </row>
1381 <row><entry></entry></row>
1382 <row>
1383 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_BITRATE_PEAK</constant>&nbsp;</entry>
1384 <entry>integer</entry>
1385 </row><row><entry spanname="descr">Peak video bitrate in
1386bits per second. Must be larger or equal to the average video bitrate.
1387It is ignored if the video bitrate mode is set to constant
1388bitrate.</entry>
1389 </row>
1390 <row><entry></entry></row>
1391 <row>
1392 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION</constant>&nbsp;</entry>
1393 <entry>integer</entry>
1394 </row><row><entry spanname="descr">For every captured
1395frame, skip this many subsequent frames (default 0).</entry>
1396 </row>
1397 <row><entry></entry></row>
1398 <row>
1399 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MUTE</constant>&nbsp;</entry>
1400 <entry>boolean</entry>
1401 </row>
1402 <row><entry spanname="descr">"Mutes" the video to a
1403fixed color when capturing. This is useful for testing, to produce a
1404fixed video bitstream. 0 = unmuted, 1 = muted.</entry>
1405 </row>
1406 <row><entry></entry></row>
1407 <row>
1408 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MUTE_YUV</constant>&nbsp;</entry>
1409 <entry>integer</entry>
1410 </row><row><entry spanname="descr">Sets the "mute" color
1411of the video. The supplied 32-bit integer is interpreted as follows (bit
14120 = least significant bit):</entry>
1413 </row>
1414 <row>
1415 <entrytbl spanname="descr" cols="2">
1416 <tbody valign="top">
1417 <row>
1418 <entry>Bit 0:7</entry>
1419 <entry>V chrominance information</entry>
1420 </row>
1421 <row>
1422 <entry>Bit 8:15</entry>
1423 <entry>U chrominance information</entry>
1424 </row>
1425 <row>
1426 <entry>Bit 16:23</entry>
1427 <entry>Y luminance information</entry>
1428 </row>
1429 <row>
1430 <entry>Bit 24:31</entry>
1431 <entry>Must be zero.</entry>
1432 </row>
1433 </tbody>
1434 </entrytbl>
1435 </row>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001436
1437
1438 <row><entry></entry></row>
1439 <row>
1440 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE</constant>&nbsp;</entry>
1441 <entry>boolean</entry>
1442 </row>
1443 <row><entry spanname="descr">If enabled the decoder expects to receive a single slice per buffer, otherwise
1444the decoder expects a single frame in per buffer. Applicable to the decoder, all codecs.
1445</entry>
1446 </row>
1447
1448 <row><entry></entry></row>
1449 <row>
1450 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE</constant>&nbsp;</entry>
1451 <entry>boolean</entry>
1452 </row>
1453 <row><entry spanname="descr">Enable writing sample aspect ratio in the Video Usability Information.
1454Applicable to the H264 encoder.</entry>
1455 </row>
1456
1457 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001458 <row id="v4l2-mpeg-video-h264-vui-sar-idc">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001459 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC</constant>&nbsp;</entry>
1460 <entry>enum&nbsp;v4l2_mpeg_video_h264_vui_sar_idc</entry>
1461 </row>
1462 <row><entry spanname="descr">VUI sample aspect ratio indicator for H.264 encoding. The value
1463is defined in the table E-1 in the standard. Applicable to the H264 encoder.</entry>
1464 </row>
1465 <row>
1466 <entrytbl spanname="descr" cols="2">
1467 <tbody valign="top">
1468
1469 <row>
1470 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED</constant>&nbsp;</entry>
1471 <entry>Unspecified</entry>
1472 </row>
1473 <row>
1474 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1</constant>&nbsp;</entry>
1475 <entry>1x1</entry>
1476 </row>
1477 <row>
1478 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11</constant>&nbsp;</entry>
1479 <entry>12x11</entry>
1480 </row>
1481 <row>
1482 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11</constant>&nbsp;</entry>
1483 <entry>10x11</entry>
1484 </row>
1485 <row>
1486 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11</constant>&nbsp;</entry>
1487 <entry>16x11</entry>
1488 </row>
1489 <row>
1490 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33</constant>&nbsp;</entry>
1491 <entry>40x33</entry>
1492 </row>
1493 <row>
1494 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11</constant>&nbsp;</entry>
1495 <entry>24x11</entry>
1496 </row>
1497 <row>
1498 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11</constant>&nbsp;</entry>
1499 <entry>20x11</entry>
1500 </row>
1501 <row>
1502 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11</constant>&nbsp;</entry>
1503 <entry>32x11</entry>
1504 </row>
1505 <row>
1506 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33</constant>&nbsp;</entry>
1507 <entry>80x33</entry>
1508 </row>
1509 <row>
1510 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11</constant>&nbsp;</entry>
1511 <entry>18x11</entry>
1512 </row>
1513 <row>
1514 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11</constant>&nbsp;</entry>
1515 <entry>15x11</entry>
1516 </row>
1517 <row>
1518 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33</constant>&nbsp;</entry>
1519 <entry>64x33</entry>
1520 </row>
1521 <row>
1522 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99</constant>&nbsp;</entry>
1523 <entry>160x99</entry>
1524 </row>
1525 <row>
1526 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3</constant>&nbsp;</entry>
1527 <entry>4x3</entry>
1528 </row>
1529 <row>
1530 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2</constant>&nbsp;</entry>
1531 <entry>3x2</entry>
1532 </row>
1533 <row>
1534 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1</constant>&nbsp;</entry>
1535 <entry>2x1</entry>
1536 </row>
1537 <row>
1538 <entry><constant>V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED</constant>&nbsp;</entry>
1539 <entry>Extended SAR</entry>
1540 </row>
1541 </tbody>
1542 </entrytbl>
1543 </row>
1544
1545 <row><entry></entry></row>
1546 <row>
1547 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH</constant>&nbsp;</entry>
1548 <entry>integer</entry>
1549 </row>
1550 <row><entry spanname="descr">Extended sample aspect ratio width for H.264 VUI encoding.
1551Applicable to the H264 encoder.</entry>
1552 </row>
1553
1554 <row><entry></entry></row>
1555 <row>
1556 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT</constant>&nbsp;</entry>
1557 <entry>integer</entry>
1558 </row>
1559 <row><entry spanname="descr">Extended sample aspect ratio height for H.264 VUI encoding.
1560Applicable to the H264 encoder.</entry>
1561 </row>
1562
1563 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001564 <row id="v4l2-mpeg-video-h264-level">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001565 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_LEVEL</constant>&nbsp;</entry>
1566 <entry>enum&nbsp;v4l2_mpeg_video_h264_level</entry>
1567 </row>
1568 <row><entry spanname="descr">The level information for the H264 video elementary stream.
1569Applicable to the H264 encoder.
1570Possible values are:</entry>
1571 </row>
1572 <row>
1573 <entrytbl spanname="descr" cols="2">
1574 <tbody valign="top">
1575 <row>
1576 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_1_0</constant>&nbsp;</entry>
1577 <entry>Level 1.0</entry>
1578 </row>
1579 <row>
1580 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_1B</constant>&nbsp;</entry>
1581 <entry>Level 1B</entry>
1582 </row>
1583 <row>
1584 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_1_1</constant>&nbsp;</entry>
1585 <entry>Level 1.1</entry>
1586 </row>
1587 <row>
1588 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_1_2</constant>&nbsp;</entry>
1589 <entry>Level 1.2</entry>
1590 </row>
1591 <row>
1592 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_1_3</constant>&nbsp;</entry>
1593 <entry>Level 1.3</entry>
1594 </row>
1595 <row>
1596 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_2_0</constant>&nbsp;</entry>
1597 <entry>Level 2.0</entry>
1598 </row>
1599 <row>
1600 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_2_1</constant>&nbsp;</entry>
1601 <entry>Level 2.1</entry>
1602 </row>
1603 <row>
1604 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_2_2</constant>&nbsp;</entry>
1605 <entry>Level 2.2</entry>
1606 </row>
1607 <row>
1608 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_3_0</constant>&nbsp;</entry>
1609 <entry>Level 3.0</entry>
1610 </row>
1611 <row>
1612 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_3_1</constant>&nbsp;</entry>
1613 <entry>Level 3.1</entry>
1614 </row>
1615 <row>
1616 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_3_2</constant>&nbsp;</entry>
1617 <entry>Level 3.2</entry>
1618 </row>
1619 <row>
1620 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_4_0</constant>&nbsp;</entry>
1621 <entry>Level 4.0</entry>
1622 </row>
1623 <row>
1624 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_4_1</constant>&nbsp;</entry>
1625 <entry>Level 4.1</entry>
1626 </row>
1627 <row>
1628 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_4_2</constant>&nbsp;</entry>
1629 <entry>Level 4.2</entry>
1630 </row>
1631 <row>
1632 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_5_0</constant>&nbsp;</entry>
1633 <entry>Level 5.0</entry>
1634 </row>
1635 <row>
1636 <entry><constant>V4L2_MPEG_VIDEO_H264_LEVEL_5_1</constant>&nbsp;</entry>
1637 <entry>Level 5.1</entry>
1638 </row>
1639 </tbody>
1640 </entrytbl>
1641 </row>
1642
1643 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001644 <row id="v4l2-mpeg-video-mpeg4-level">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001645 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL</constant>&nbsp;</entry>
1646 <entry>enum&nbsp;v4l2_mpeg_video_mpeg4_level</entry>
1647 </row>
1648 <row><entry spanname="descr">The level information for the MPEG4 elementary stream.
1649Applicable to the MPEG4 encoder.
1650Possible values are:</entry>
1651 </row>
1652 <row>
1653 <entrytbl spanname="descr" cols="2">
1654 <tbody valign="top">
1655 <row>
1656 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_0</constant>&nbsp;</entry>
1657 <entry>Level 0</entry>
1658 </row>
1659 <row>
1660 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_0B</constant>&nbsp;</entry>
1661 <entry>Level 0b</entry>
1662 </row>
1663 <row>
1664 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_1</constant>&nbsp;</entry>
1665 <entry>Level 1</entry>
1666 </row>
1667 <row>
1668 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_2</constant>&nbsp;</entry>
1669 <entry>Level 2</entry>
1670 </row>
1671 <row>
1672 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_3</constant>&nbsp;</entry>
1673 <entry>Level 3</entry>
1674 </row>
1675 <row>
1676 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_3B</constant>&nbsp;</entry>
1677 <entry>Level 3b</entry>
1678 </row>
1679 <row>
1680 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_4</constant>&nbsp;</entry>
1681 <entry>Level 4</entry>
1682 </row>
1683 <row>
1684 <entry><constant>V4L2_MPEG_VIDEO_LEVEL_5</constant>&nbsp;</entry>
1685 <entry>Level 5</entry>
1686 </row>
1687 </tbody>
1688 </entrytbl>
1689 </row>
1690
1691 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001692 <row id="v4l2-mpeg-video-h264-profile">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001693 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_PROFILE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03001694 <entry>enum&nbsp;v4l2_mpeg_video_h264_profile</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001695 </row>
1696 <row><entry spanname="descr">The profile information for H264.
1697Applicable to the H264 encoder.
1698Possible values are:</entry>
1699 </row>
1700 <row>
1701 <entrytbl spanname="descr" cols="2">
1702 <tbody valign="top">
1703 <row>
1704 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE</constant>&nbsp;</entry>
1705 <entry>Baseline profile</entry>
1706 </row>
1707 <row>
1708 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE</constant>&nbsp;</entry>
1709 <entry>Constrained Baseline profile</entry>
1710 </row>
1711 <row>
1712 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_MAIN</constant>&nbsp;</entry>
1713 <entry>Main profile</entry>
1714 </row>
1715 <row>
1716 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED</constant>&nbsp;</entry>
1717 <entry>Extended profile</entry>
1718 </row>
1719 <row>
1720 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH</constant>&nbsp;</entry>
1721 <entry>High profile</entry>
1722 </row>
1723 <row>
1724 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10</constant>&nbsp;</entry>
1725 <entry>High 10 profile</entry>
1726 </row>
1727 <row>
1728 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422</constant>&nbsp;</entry>
1729 <entry>High 422 profile</entry>
1730 </row>
1731 <row>
1732 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE</constant>&nbsp;</entry>
1733 <entry>High 444 Predictive profile</entry>
1734 </row>
1735 <row>
1736 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA</constant>&nbsp;</entry>
1737 <entry>High 10 Intra profile</entry>
1738 </row>
1739 <row>
1740 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA</constant>&nbsp;</entry>
1741 <entry>High 422 Intra profile</entry>
1742 </row>
1743 <row>
1744 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA</constant>&nbsp;</entry>
1745 <entry>High 444 Intra profile</entry>
1746 </row>
1747 <row>
1748 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA</constant>&nbsp;</entry>
1749 <entry>CAVLC 444 Intra profile</entry>
1750 </row>
1751 <row>
1752 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE</constant>&nbsp;</entry>
1753 <entry>Scalable Baseline profile</entry>
1754 </row>
1755 <row>
1756 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH</constant>&nbsp;</entry>
1757 <entry>Scalable High profile</entry>
1758 </row>
1759 <row>
1760 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA</constant>&nbsp;</entry>
1761 <entry>Scalable High Intra profile</entry>
1762 </row>
1763 <row>
1764 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH</constant>&nbsp;</entry>
1765 <entry>Stereo High profile</entry>
1766 </row>
1767 <row>
1768 <entry><constant>V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH</constant>&nbsp;</entry>
1769 <entry>Multiview High profile</entry>
1770 </row>
1771
1772 </tbody>
1773 </entrytbl>
1774 </row>
1775
1776 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001777 <row id="v4l2-mpeg-video-mpeg4-profile">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001778 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03001779 <entry>enum&nbsp;v4l2_mpeg_video_mpeg4_profile</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001780 </row>
1781 <row><entry spanname="descr">The profile information for MPEG4.
1782Applicable to the MPEG4 encoder.
1783Possible values are:</entry>
1784 </row>
1785 <row>
1786 <entrytbl spanname="descr" cols="2">
1787 <tbody valign="top">
1788 <row>
1789 <entry><constant>V4L2_MPEG_VIDEO_PROFILE_SIMPLE</constant>&nbsp;</entry>
1790 <entry>Simple profile</entry>
1791 </row>
1792 <row>
1793 <entry><constant>V4L2_MPEG_VIDEO_PROFILE_ADVANCED_SIMPLE</constant>&nbsp;</entry>
1794 <entry>Advanced Simple profile</entry>
1795 </row>
1796 <row>
1797 <entry><constant>V4L2_MPEG_VIDEO_PROFILE_CORE</constant>&nbsp;</entry>
1798 <entry>Core profile</entry>
1799 </row>
1800 <row>
1801 <entry><constant>V4L2_MPEG_VIDEO_PROFILE_SIMPLE_SCALABLE</constant>&nbsp;</entry>
1802 <entry>Simple Scalable profile</entry>
1803 </row>
1804 <row>
1805 <entry><constant>V4L2_MPEG_VIDEO_PROFILE_ADVANCED_CODING_EFFICIENCY</constant>&nbsp;</entry>
1806 <entry></entry>
1807 </row>
1808 </tbody>
1809 </entrytbl>
1810 </row>
1811
1812 <row><entry></entry></row>
1813 <row>
1814 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MAX_REF_PIC</constant>&nbsp;</entry>
1815 <entry>integer</entry>
1816 </row>
1817 <row><entry spanname="descr">The maximum number of reference pictures used for encoding.
1818Applicable to the encoder.
1819</entry>
1820 </row>
1821
1822 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001823 <row id="v4l2-mpeg-video-multi-slice-mode">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001824 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03001825 <entry>enum&nbsp;v4l2_mpeg_video_multi_slice_mode</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001826 </row>
1827 <row><entry spanname="descr">Determines how the encoder should handle division of frame into slices.
1828Applicable to the encoder.
1829Possible values are:</entry>
1830 </row>
1831 <row>
1832 <entrytbl spanname="descr" cols="2">
1833 <tbody valign="top">
1834 <row>
1835 <entry><constant>V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE</constant>&nbsp;</entry>
1836 <entry>Single slice per frame.</entry>
1837 </row>
1838 <row>
1839 <entry><constant>V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB</constant>&nbsp;</entry>
1840 <entry>Multiple slices with set maximum number of macroblocks per slice.</entry>
1841 </row>
1842 <row>
1843 <entry><constant>V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES</constant>&nbsp;</entry>
1844 <entry>Multiple slice with set maximum size in bytes per slice.</entry>
1845 </row>
1846 </tbody>
1847 </entrytbl>
1848 </row>
1849
1850 <row><entry></entry></row>
1851 <row>
1852 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB</constant>&nbsp;</entry>
1853 <entry>integer</entry>
1854 </row>
1855 <row><entry spanname="descr">The maximum number of macroblocks in a slice. Used when
1856<constant>V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE</constant> is set to <constant>V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_MB</constant>.
1857Applicable to the encoder.</entry>
1858 </row>
1859
1860 <row><entry></entry></row>
1861 <row>
1862 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES</constant>&nbsp;</entry>
1863 <entry>integer</entry>
1864 </row>
1865 <row><entry spanname="descr">The maximum size of a slice in bytes. Used when
1866<constant>V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE</constant> is set to <constant>V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_MAX_BYTES</constant>.
1867Applicable to the encoder.</entry>
1868 </row>
1869
1870 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001871 <row id="v4l2-mpeg-video-h264-loop-filter-mode">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001872 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03001873 <entry>enum&nbsp;v4l2_mpeg_video_h264_loop_filter_mode</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001874 </row>
1875 <row><entry spanname="descr">Loop filter mode for H264 encoder.
1876Possible values are:</entry>
1877 </row>
1878 <row>
1879 <entrytbl spanname="descr" cols="2">
1880 <tbody valign="top">
1881 <row>
1882 <entry><constant>V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED</constant>&nbsp;</entry>
1883 <entry>Loop filter is enabled.</entry>
1884 </row>
1885 <row>
1886 <entry><constant>V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED</constant>&nbsp;</entry>
1887 <entry>Loop filter is disabled.</entry>
1888 </row>
1889 <row>
1890 <entry><constant>V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY</constant>&nbsp;</entry>
1891 <entry>Loop filter is disabled at the slice boundary.</entry>
1892 </row>
1893 </tbody>
1894 </entrytbl>
1895 </row>
1896
1897 <row><entry></entry></row>
1898 <row>
1899 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA</constant>&nbsp;</entry>
1900 <entry>integer</entry>
1901 </row>
1902 <row><entry spanname="descr">Loop filter alpha coefficient, defined in the H264 standard.
1903Applicable to the H264 encoder.</entry>
1904 </row>
1905
1906 <row><entry></entry></row>
1907 <row>
1908 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA</constant>&nbsp;</entry>
1909 <entry>integer</entry>
1910 </row>
1911 <row><entry spanname="descr">Loop filter beta coefficient, defined in the H264 standard.
1912Applicable to the H264 encoder.</entry>
1913 </row>
1914
1915 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03001916 <row id="v4l2-mpeg-video-h264-entropy-mode">
Kamil Debskie65e4f12011-06-14 10:31:04 -03001917 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03001918 <entry>enum&nbsp;v4l2_mpeg_video_h264_entropy_mode</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03001919 </row>
1920 <row><entry spanname="descr">Entropy coding mode for H264 - CABAC/CAVALC.
1921Applicable to the H264 encoder.
1922Possible values are:</entry>
1923 </row>
1924 <row>
1925 <entrytbl spanname="descr" cols="2">
1926 <tbody valign="top">
1927 <row>
1928 <entry><constant>V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC</constant>&nbsp;</entry>
1929 <entry>Use CAVLC entropy coding.</entry>
1930 </row>
1931 <row>
1932 <entry><constant>V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC</constant>&nbsp;</entry>
1933 <entry>Use CABAC entropy coding.</entry>
1934 </row>
1935 </tbody>
1936 </entrytbl>
1937 </row>
1938
1939 <row><entry></entry></row>
1940 <row>
1941 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM</constant>&nbsp;</entry>
1942 <entry>boolean</entry>
1943 </row>
1944 <row><entry spanname="descr">Enable 8X8 transform for H264. Applicable to the H264 encoder.</entry>
1945 </row>
1946
1947 <row><entry></entry></row>
1948 <row>
1949 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB</constant>&nbsp;</entry>
1950 <entry>integer</entry>
1951 </row>
1952 <row><entry spanname="descr">Cyclic intra macroblock refresh. This is the number of continuous macroblocks
1953refreshed every frame. Each frame a succesive set of macroblocks is refreshed until the cycle completes and starts from the
1954top of the frame. Applicable to H264, H263 and MPEG4 encoder.</entry>
1955 </row>
1956
1957 <row><entry></entry></row>
1958 <row>
1959 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE</constant>&nbsp;</entry>
1960 <entry>boolean</entry>
1961 </row>
1962 <row><entry spanname="descr">Frame level rate control enable.
1963If this control is disabled then the quantization parameter for each frame type is constant and set with appropriate controls
1964(e.g. <constant>V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP</constant>).
1965If frame rate control is enabled then quantization parameter is adjusted to meet the chosen bitrate. Minimum and maximum value
1966for the quantization parameter can be set with appropriate controls (e.g. <constant>V4L2_CID_MPEG_VIDEO_H263_MIN_QP</constant>).
1967Applicable to encoders.</entry>
1968 </row>
1969
1970 <row><entry></entry></row>
1971 <row>
1972 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE</constant>&nbsp;</entry>
1973 <entry>boolean</entry>
1974 </row>
1975 <row><entry spanname="descr">Macroblock level rate control enable.
1976Applicable to the MPEG4 and H264 encoders.</entry>
1977 </row>
1978
1979 <row><entry></entry></row>
1980 <row>
1981 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_QPEL</constant>&nbsp;</entry>
1982 <entry>boolean</entry>
1983 </row>
1984 <row><entry spanname="descr">Quarter pixel motion estimation for MPEG4. Applicable to the MPEG4 encoder.</entry>
1985 </row>
1986
1987 <row><entry></entry></row>
1988 <row>
1989 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP</constant>&nbsp;</entry>
1990 <entry>integer</entry>
1991 </row>
1992 <row><entry spanname="descr">Quantization parameter for an I frame for H263. Valid range: from 1 to 31.</entry>
1993 </row>
1994
1995 <row><entry></entry></row>
1996 <row>
1997 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H263_MIN_QP</constant>&nbsp;</entry>
1998 <entry>integer</entry>
1999 </row>
2000 <row><entry spanname="descr">Minimum quantization parameter for H263. Valid range: from 1 to 31.</entry>
2001 </row>
2002
2003 <row><entry></entry></row>
2004 <row>
2005 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H263_MAX_QP</constant>&nbsp;</entry>
2006 <entry>integer</entry>
2007 </row>
2008 <row><entry spanname="descr">Maximum quantization parameter for H263. Valid range: from 1 to 31.</entry>
2009 </row>
2010
2011 <row><entry></entry></row>
2012 <row>
2013 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP</constant>&nbsp;</entry>
2014 <entry>integer</entry>
2015 </row>
2016 <row><entry spanname="descr">Quantization parameter for an P frame for H263. Valid range: from 1 to 31.</entry>
2017 </row>
2018
2019 <row><entry></entry></row>
2020 <row>
2021 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP</constant>&nbsp;</entry>
2022 <entry>integer</entry>
2023 </row>
2024 <row><entry spanname="descr">Quantization parameter for an B frame for H263. Valid range: from 1 to 31.</entry>
2025 </row>
2026
2027 <row><entry></entry></row>
2028 <row>
2029 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP</constant>&nbsp;</entry>
2030 <entry>integer</entry>
2031 </row>
2032 <row><entry spanname="descr">Quantization parameter for an I frame for H264. Valid range: from 0 to 51.</entry>
2033 </row>
2034
2035 <row><entry></entry></row>
2036 <row>
2037 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_MIN_QP</constant>&nbsp;</entry>
2038 <entry>integer</entry>
2039 </row>
2040 <row><entry spanname="descr">Minimum quantization parameter for H264. Valid range: from 0 to 51.</entry>
2041 </row>
2042
2043 <row><entry></entry></row>
2044 <row>
2045 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_MAX_QP</constant>&nbsp;</entry>
2046 <entry>integer</entry>
2047 </row>
2048 <row><entry spanname="descr">Maximum quantization parameter for H264. Valid range: from 0 to 51.</entry>
2049 </row>
2050
2051 <row><entry></entry></row>
2052 <row>
2053 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP</constant>&nbsp;</entry>
2054 <entry>integer</entry>
2055 </row>
2056 <row><entry spanname="descr">Quantization parameter for an P frame for H264. Valid range: from 0 to 51.</entry>
2057 </row>
2058
2059 <row><entry></entry></row>
2060 <row>
2061 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP</constant>&nbsp;</entry>
2062 <entry>integer</entry>
2063 </row>
2064 <row><entry spanname="descr">Quantization parameter for an B frame for H264. Valid range: from 0 to 51.</entry>
2065 </row>
2066
2067 <row><entry></entry></row>
2068 <row>
2069 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP</constant>&nbsp;</entry>
2070 <entry>integer</entry>
2071 </row>
2072 <row><entry spanname="descr">Quantization parameter for an I frame for MPEG4. Valid range: from 1 to 31.</entry>
2073 </row>
2074
2075 <row><entry></entry></row>
2076 <row>
2077 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP</constant>&nbsp;</entry>
2078 <entry>integer</entry>
2079 </row>
2080 <row><entry spanname="descr">Minimum quantization parameter for MPEG4. Valid range: from 1 to 31.</entry>
2081 </row>
2082
2083 <row><entry></entry></row>
2084 <row>
2085 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP</constant>&nbsp;</entry>
2086 <entry>integer</entry>
2087 </row>
2088 <row><entry spanname="descr">Maximum quantization parameter for MPEG4. Valid range: from 1 to 31.</entry>
2089 </row>
2090
2091 <row><entry></entry></row>
2092 <row>
2093 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP</constant>&nbsp;</entry>
2094 <entry>integer</entry>
2095 </row>
2096 <row><entry spanname="descr">Quantization parameter for an P frame for MPEG4. Valid range: from 1 to 31.</entry>
2097 </row>
2098
2099 <row><entry></entry></row>
2100 <row>
2101 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP</constant>&nbsp;</entry>
2102 <entry>integer</entry>
2103 </row>
2104 <row><entry spanname="descr">Quantization parameter for an B frame for MPEG4. Valid range: from 1 to 31.</entry>
2105 </row>
2106
2107 <row><entry></entry></row>
2108 <row>
2109 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_VBV_SIZE</constant>&nbsp;</entry>
2110 <entry>integer</entry>
2111 </row>
2112 <row><entry spanname="descr">The Video Buffer Verifier size in kilobytes, it is used as a limitation of frame skip.
2113The VBV is defined in the standard as a mean to verify that the produced stream will be succesfully decoded.
2114The standard describes it as "Part of a hypothetical decoder that is conceptually connected to the
2115output of the encoder. Its purpose is to provide a constraint on the variability of the data rate that an
2116encoder or editing process may produce.".
2117Applicable to the MPEG1, MPEG2, MPEG4 encoders.</entry>
2118 </row>
2119
2120 <row><entry></entry></row>
2121 <row>
2122 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE</constant>&nbsp;</entry>
2123 <entry>integer</entry>
2124 </row>
2125 <row><entry spanname="descr">The Coded Picture Buffer size in kilobytes, it is used as a limitation of frame skip.
2126The CPB is defined in the H264 standard as a mean to verify that the produced stream will be succesfully decoded.
2127Applicable to the H264 encoder.</entry>
2128 </row>
2129
2130 <row><entry></entry></row>
2131 <row>
2132 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_H264_I_PERIOD</constant>&nbsp;</entry>
2133 <entry>integer</entry>
2134 </row>
2135 <row><entry spanname="descr">Period between I-frames in the open GOP for H264. In case of an open GOP
2136this is the period between two I-frames. The period between IDR (Instantaneous Decoding Refresh) frames is taken from the GOP_SIZE control.
2137An IDR frame, which stands for Instantaneous Decoding Refresh is an I-frame after which no prior frames are
2138referenced. This means that a stream can be restarted from an IDR frame without the need to store or decode any
2139previous frames. Applicable to the H264 encoder.</entry>
2140 </row>
2141
2142 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03002143 <row id="v4l2-mpeg-video-header-mode">
Kamil Debskie65e4f12011-06-14 10:31:04 -03002144 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_HEADER_MODE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03002145 <entry>enum&nbsp;v4l2_mpeg_video_header_mode</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03002146 </row>
2147 <row><entry spanname="descr">Determines whether the header is returned as the first buffer or is
2148it returned together with the first frame. Applicable to encoders.
2149Possible values are:</entry>
2150 </row>
2151 <row>
2152 <entrytbl spanname="descr" cols="2">
2153 <tbody valign="top">
2154 <row>
2155 <entry><constant>V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE</constant>&nbsp;</entry>
2156 <entry>The stream header is returned separately in the first buffer.</entry>
2157 </row>
2158 <row>
2159 <entry><constant>V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME</constant>&nbsp;</entry>
2160 <entry>The stream header is returned together with the first encoded frame.</entry>
2161 </row>
2162 </tbody>
2163 </entrytbl>
2164 </row>
2165 <row><entry></entry></row>
2166 <row>
2167 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER</constant>&nbsp;</entry>
2168 <entry>boolean</entry>
2169 </row><row><entry spanname="descr">Enabled the deblocking post processing filter for MPEG4 decoder.
2170Applicable to the MPEG4 decoder.</entry>
2171 </row>
2172 <row><entry></entry></row>
2173 <row>
2174 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_RES</constant>&nbsp;</entry>
2175 <entry>integer</entry>
2176 </row><row><entry spanname="descr">vop_time_increment_resolution value for MPEG4. Applicable to the MPEG4 encoder.</entry>
2177 </row>
2178 <row><entry></entry></row>
2179 <row>
2180 <entry spanname="id"><constant>V4L2_CID_MPEG_VIDEO_MPEG4_VOP_TIME_INC</constant>&nbsp;</entry>
2181 <entry>integer</entry>
2182 </row><row><entry spanname="descr">vop_time_increment value for MPEG4. Applicable to the MPEG4 encoder.</entry>
2183 </row>
2184
2185 </tbody>
2186 </tgroup>
2187 </table>
2188 </section>
2189
2190 <section>
2191 <title>MFC 5.1 MPEG Controls</title>
2192
2193 <para>The following MPEG class controls deal with MPEG
2194decoding and encoding settings that are specific to the Multi Format Codec 5.1 device present
2195in the S5P family of SoCs by Samsung.
2196</para>
2197
2198 <table pgwide="1" frame="none" id="mfc51-control-id">
2199 <title>MFC 5.1 Control IDs</title>
2200 <tgroup cols="4">
2201 <colspec colname="c1" colwidth="1*" />
2202 <colspec colname="c2" colwidth="6*" />
2203 <colspec colname="c3" colwidth="2*" />
2204 <colspec colname="c4" colwidth="6*" />
2205 <spanspec namest="c1" nameend="c2" spanname="id" />
2206 <spanspec namest="c2" nameend="c4" spanname="descr" />
2207 <thead>
2208 <row>
2209 <entry spanname="id" align="left">ID</entry>
2210 <entry align="left">Type</entry>
2211 </row><row><entry spanname="descr" align="left">Description</entry>
2212 </row>
2213 </thead>
2214 <tbody valign="top">
2215 <row><entry></entry></row>
2216 <row>
2217 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE</constant>&nbsp;</entry>
2218 <entry>integer</entry>
2219 </row><row><entry spanname="descr">If the display delay is enabled then the decoder has to return a
2220CAPTURE buffer after processing a certain number of OUTPUT buffers. If this number is low, then it may result in
2221buffers not being dequeued in display order. In addition hardware may still use those buffers as reference, thus
2222application should not write to those buffers. This feature can be used for example for generating thumbnails of videos.
2223Applicable to the H264 decoder.
2224 </entry>
2225 </row>
2226 <row><entry></entry></row>
2227 <row>
2228 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY</constant>&nbsp;</entry>
2229 <entry>integer</entry>
2230 </row><row><entry spanname="descr">Display delay value for H264 decoder.
2231The decoder is forced to return a decoded frame after the set 'display delay' number of frames. If this number is
2232low it may result in frames returned out of dispaly order, in addition the hardware may still be using the returned buffer
2233as a reference picture for subsequent frames.
2234</entry>
2235 </row>
2236 <row><entry></entry></row>
2237 <row>
2238 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P</constant>&nbsp;</entry>
2239 <entry>integer</entry>
2240 </row><row><entry spanname="descr">The number of reference pictures used for encoding a P picture.
2241Applicable to the H264 encoder.</entry>
2242 </row>
2243 <row><entry></entry></row>
2244 <row>
2245 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_PADDING</constant>&nbsp;</entry>
2246 <entry>boolean</entry>
2247 </row><row><entry spanname="descr">Padding enable in the encoder - use a color instead of repeating border pixels.
2248Applicable to encoders.</entry>
2249 </row>
2250 <row><entry></entry></row>
2251 <row>
2252 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV</constant>&nbsp;</entry>
2253 <entry>integer</entry>
2254 </row><row><entry spanname="descr">Padding color in the encoder. Applicable to encoders. The supplied 32-bit integer is interpreted as follows (bit
22550 = least significant bit):</entry>
2256 </row>
2257 <row>
2258 <entrytbl spanname="descr" cols="2">
2259 <tbody valign="top">
2260 <row>
2261 <entry>Bit 0:7</entry>
2262 <entry>V chrominance information</entry>
2263 </row>
2264 <row>
2265 <entry>Bit 8:15</entry>
2266 <entry>U chrominance information</entry>
2267 </row>
2268 <row>
2269 <entry>Bit 16:23</entry>
2270 <entry>Y luminance information</entry>
2271 </row>
2272 <row>
2273 <entry>Bit 24:31</entry>
2274 <entry>Must be zero.</entry>
2275 </row>
2276 </tbody>
2277 </entrytbl>
2278 </row>
2279 <row><entry></entry></row>
2280 <row>
2281 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF</constant>&nbsp;</entry>
2282 <entry>integer</entry>
2283 </row><row><entry spanname="descr">Reaction coefficient for MFC rate control. Applicable to encoders.
2284<para>Note 1: Valid only when the frame level RC is enabled.</para>
2285<para>Note 2: For tight CBR, this field must be small (ex. 2 ~ 10).
2286For VBR, this field must be large (ex. 100 ~ 1000).</para>
2287<para>Note 3: It is not recommended to use the greater number than FRAME_RATE * (10^9 / BIT_RATE).</para>
2288</entry>
2289 </row>
2290 <row><entry></entry></row>
2291 <row>
2292 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK</constant>&nbsp;</entry>
2293 <entry>boolean</entry>
2294 </row><row><entry spanname="descr">Adaptive rate control for dark region.
2295Valid only when H.264 and macroblock level RC is enabled (<constant>V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE</constant>).
2296Applicable to the H264 encoder.</entry>
2297 </row>
2298 <row><entry></entry></row>
2299 <row>
2300 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH</constant>&nbsp;</entry>
2301 <entry>boolean</entry>
2302 </row><row><entry spanname="descr">Adaptive rate control for smooth region.
2303Valid only when H.264 and macroblock level RC is enabled (<constant>V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE</constant>).
2304Applicable to the H264 encoder.</entry>
2305 </row>
2306 <row><entry></entry></row>
2307 <row>
2308 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC</constant>&nbsp;</entry>
2309 <entry>boolean</entry>
2310 </row><row><entry spanname="descr">Adaptive rate control for static region.
2311Valid only when H.264 and macroblock level RC is enabled (<constant>V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE</constant>).
2312Applicable to the H264 encoder.</entry>
2313 </row>
2314 <row><entry></entry></row>
2315 <row>
2316 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY</constant>&nbsp;</entry>
2317 <entry>boolean</entry>
2318 </row><row><entry spanname="descr">Adaptive rate control for activity region.
2319Valid only when H.264 and macroblock level RC is enabled (<constant>V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE</constant>).
2320Applicable to the H264 encoder.</entry>
2321 </row>
2322 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03002323 <row id="v4l2-mpeg-mfc51-video-frame-skip-mode">
Kamil Debskie65e4f12011-06-14 10:31:04 -03002324 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03002325 <entry>enum&nbsp;v4l2_mpeg_mfc51_video_frame_skip_mode</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03002326 </row>
2327 <row><entry spanname="descr">
2328Indicates in what conditions the encoder should skip frames. If encoding a frame would cause the encoded stream to be larger then
2329a chosen data limit then the frame will be skipped.
2330Possible values are:</entry>
2331 </row>
2332 <row>
2333 <entrytbl spanname="descr" cols="2">
2334 <tbody valign="top">
2335 <row>
2336 <entry><constant>V4L2_MPEG_MFC51_FRAME_SKIP_MODE_DISABLED</constant>&nbsp;</entry>
2337 <entry>Frame skip mode is disabled.</entry>
2338 </row>
2339 <row>
2340 <entry><constant>V4L2_MPEG_MFC51_FRAME_SKIP_MODE_LEVEL_LIMIT</constant>&nbsp;</entry>
2341 <entry>Frame skip mode enabled and buffer limit is set by the chosen level and is defined by the standard.</entry>
2342 </row>
2343 <row>
2344 <entry><constant>V4L2_MPEG_MFC51_FRAME_SKIP_MODE_BUF_LIMIT</constant>&nbsp;</entry>
2345 <entry>Frame skip mode enabled and buffer limit is set by the VBV (MPEG1/2/4) or CPB (H264) buffer size control.</entry>
2346 </row>
2347 </tbody>
2348 </entrytbl>
2349 </row>
2350 <row><entry></entry></row>
2351 <row>
2352 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT</constant>&nbsp;</entry>
2353 <entry>integer</entry>
2354 </row><row><entry spanname="descr">Enable rate-control with fixed target bit.
2355If this setting is enabled, then the rate control logic of the encoder will calculate the average bitrate
2356for a GOP and keep it below or equal the set bitrate target. Otherwise the rate control logic calculates the
2357overall average bitrate for the stream and keeps it below or equal to the set bitrate. In the first case
2358the average bitrate for the whole stream will be smaller then the set bitrate. This is caused because the
2359average is calculated for smaller number of frames, on the other hand enabling this setting will ensure that
2360the stream will meet tight bandwidth contraints. Applicable to encoders.
2361</entry>
2362 </row>
2363 <row><entry></entry></row>
Kamil Debski6a02a332011-08-02 12:53:49 -03002364 <row id="v4l2-mpeg-mfc51-video-force-frame-type">
Kamil Debskie65e4f12011-06-14 10:31:04 -03002365 <entry spanname="id"><constant>V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE</constant>&nbsp;</entry>
Kamil Debski6a02a332011-08-02 12:53:49 -03002366 <entry>enum&nbsp;v4l2_mpeg_mfc51_video_force_frame_type</entry>
Kamil Debskie65e4f12011-06-14 10:31:04 -03002367 </row>
2368 <row><entry spanname="descr">Force a frame type for the next queued buffer. Applicable to encoders.
2369Possible values are:</entry>
2370 </row>
2371 <row>
2372 <entrytbl spanname="descr" cols="2">
2373 <tbody valign="top">
2374 <row>
2375 <entry><constant>V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_DISABLED</constant>&nbsp;</entry>
2376 <entry>Forcing a specific frame type disabled.</entry>
2377 </row>
2378 <row>
2379 <entry><constant>V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_I_FRAME</constant>&nbsp;</entry>
2380 <entry>Force an I-frame.</entry>
2381 </row>
2382 <row>
2383 <entry><constant>V4L2_MPEG_MFC51_FORCE_FRAME_TYPE_NOT_CODED</constant>&nbsp;</entry>
2384 <entry>Force a non-coded frame.</entry>
2385 </row>
2386 </tbody>
2387 </entrytbl>
2388 </row>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03002389 </tbody>
2390 </tgroup>
2391 </table>
2392 </section>
2393
2394 <section>
2395 <title>CX2341x MPEG Controls</title>
2396
2397 <para>The following MPEG class controls deal with MPEG
2398encoding settings that are specific to the Conexant CX23415 and
2399CX23416 MPEG encoding chips.</para>
2400
2401 <table pgwide="1" frame="none" id="cx2341x-control-id">
2402 <title>CX2341x Control IDs</title>
2403 <tgroup cols="4">
2404 <colspec colname="c1" colwidth="1*" />
2405 <colspec colname="c2" colwidth="6*" />
2406 <colspec colname="c3" colwidth="2*" />
2407 <colspec colname="c4" colwidth="6*" />
2408 <spanspec namest="c1" nameend="c2" spanname="id" />
2409 <spanspec namest="c2" nameend="c4" spanname="descr" />
2410 <thead>
2411 <row>
2412 <entry spanname="id" align="left">ID</entry>
2413 <entry align="left">Type</entry>
2414 </row><row><entry spanname="descr" align="left">Description</entry>
2415 </row>
2416 </thead>
2417 <tbody valign="top">
2418 <row><entry></entry></row>
2419 <row id="v4l2-mpeg-cx2341x-video-spatial-filter-mode">
2420 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE</constant>&nbsp;</entry>
2421 <entry>enum&nbsp;v4l2_mpeg_cx2341x_video_spatial_filter_mode</entry>
2422 </row><row><entry spanname="descr">Sets the Spatial
2423Filter mode (default <constant>MANUAL</constant>). Possible values
2424are:</entry>
2425 </row>
2426 <row>
2427 <entrytbl spanname="descr" cols="2">
2428 <tbody valign="top">
2429 <row>
2430 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL</constant>&nbsp;</entry>
2431 <entry>Choose the filter manually</entry>
2432 </row>
2433 <row>
2434 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO</constant>&nbsp;</entry>
2435 <entry>Choose the filter automatically</entry>
2436 </row>
2437 </tbody>
2438 </entrytbl>
2439 </row>
2440 <row><entry></entry></row>
2441 <row>
2442 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER</constant>&nbsp;</entry>
2443 <entry>integer&nbsp;(0-15)</entry>
2444 </row><row><entry spanname="descr">The setting for the
2445Spatial Filter. 0 = off, 15 = maximum. (Default is 0.)</entry>
2446 </row>
2447 <row><entry></entry></row>
2448 <row id="luma-spatial-filter-type">
2449 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE</constant>&nbsp;</entry>
2450 <entry>enum&nbsp;v4l2_mpeg_cx2341x_video_luma_spatial_filter_type</entry>
2451 </row><row><entry spanname="descr">Select the algorithm
2452to use for the Luma Spatial Filter (default
2453<constant>1D_HOR</constant>). Possible values:</entry>
2454 </row>
2455 <row>
2456 <entrytbl spanname="descr" cols="2">
2457 <tbody valign="top">
2458 <row>
2459 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF</constant>&nbsp;</entry>
2460 <entry>No filter</entry>
2461 </row>
2462 <row>
2463 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR</constant>&nbsp;</entry>
2464 <entry>One-dimensional horizontal</entry>
2465 </row>
2466 <row>
2467 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT</constant>&nbsp;</entry>
2468 <entry>One-dimensional vertical</entry>
2469 </row>
2470 <row>
2471 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE</constant>&nbsp;</entry>
2472 <entry>Two-dimensional separable</entry>
2473 </row>
2474 <row>
2475 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE</constant>&nbsp;</entry>
2476 <entry>Two-dimensional symmetrical
2477non-separable</entry>
2478 </row>
2479 </tbody>
2480 </entrytbl>
2481 </row>
2482 <row><entry></entry></row>
2483 <row id="chroma-spatial-filter-type">
2484 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE</constant>&nbsp;</entry>
2485 <entry>enum&nbsp;v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type</entry>
2486 </row><row><entry spanname="descr">Select the algorithm
2487for the Chroma Spatial Filter (default <constant>1D_HOR</constant>).
2488Possible values are:</entry>
2489 </row>
2490 <row>
2491 <entrytbl spanname="descr" cols="2">
2492 <tbody valign="top">
2493 <row>
2494 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF</constant>&nbsp;</entry>
2495 <entry>No filter</entry>
2496 </row>
2497 <row>
2498 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR</constant>&nbsp;</entry>
2499 <entry>One-dimensional horizontal</entry>
2500 </row>
2501 </tbody>
2502 </entrytbl>
2503 </row>
2504 <row><entry></entry></row>
2505 <row id="v4l2-mpeg-cx2341x-video-temporal-filter-mode">
2506 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE</constant>&nbsp;</entry>
2507 <entry>enum&nbsp;v4l2_mpeg_cx2341x_video_temporal_filter_mode</entry>
2508 </row><row><entry spanname="descr">Sets the Temporal
2509Filter mode (default <constant>MANUAL</constant>). Possible values
2510are:</entry>
2511 </row>
2512 <row>
2513 <entrytbl spanname="descr" cols="2">
2514 <tbody valign="top">
2515 <row>
2516 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL</constant>&nbsp;</entry>
2517 <entry>Choose the filter manually</entry>
2518 </row>
2519 <row>
2520 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO</constant>&nbsp;</entry>
2521 <entry>Choose the filter automatically</entry>
2522 </row>
2523 </tbody>
2524 </entrytbl>
2525 </row>
2526 <row><entry></entry></row>
2527 <row>
2528 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER</constant>&nbsp;</entry>
2529 <entry>integer&nbsp;(0-31)</entry>
2530 </row><row><entry spanname="descr">The setting for the
2531Temporal Filter. 0 = off, 31 = maximum. (Default is 8 for full-scale
2532capturing and 0 for scaled capturing.)</entry>
2533 </row>
2534 <row><entry></entry></row>
2535 <row id="v4l2-mpeg-cx2341x-video-median-filter-type">
2536 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE</constant>&nbsp;</entry>
2537 <entry>enum&nbsp;v4l2_mpeg_cx2341x_video_median_filter_type</entry>
2538 </row><row><entry spanname="descr">Median Filter Type
2539(default <constant>OFF</constant>). Possible values are:</entry>
2540 </row>
2541 <row>
2542 <entrytbl spanname="descr" cols="2">
2543 <tbody valign="top">
2544 <row>
2545 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF</constant>&nbsp;</entry>
2546 <entry>No filter</entry>
2547 </row>
2548 <row>
2549 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR</constant>&nbsp;</entry>
2550 <entry>Horizontal filter</entry>
2551 </row>
2552 <row>
2553 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT</constant>&nbsp;</entry>
2554 <entry>Vertical filter</entry>
2555 </row>
2556 <row>
2557 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT</constant>&nbsp;</entry>
2558 <entry>Horizontal and vertical filter</entry>
2559 </row>
2560 <row>
2561 <entry><constant>V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG</constant>&nbsp;</entry>
2562 <entry>Diagonal filter</entry>
2563 </row>
2564 </tbody>
2565 </entrytbl>
2566 </row>
2567 <row><entry></entry></row>
2568 <row>
2569 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM</constant>&nbsp;</entry>
2570 <entry>integer&nbsp;(0-255)</entry>
2571 </row><row><entry spanname="descr">Threshold above which
2572the luminance median filter is enabled (default 0)</entry>
2573 </row>
2574 <row><entry></entry></row>
2575 <row>
2576 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP</constant>&nbsp;</entry>
2577 <entry>integer&nbsp;(0-255)</entry>
2578 </row><row><entry spanname="descr">Threshold below which
2579the luminance median filter is enabled (default 255)</entry>
2580 </row>
2581 <row><entry></entry></row>
2582 <row>
2583 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM</constant>&nbsp;</entry>
2584 <entry>integer&nbsp;(0-255)</entry>
2585 </row><row><entry spanname="descr">Threshold above which
2586the chroma median filter is enabled (default 0)</entry>
2587 </row>
2588 <row><entry></entry></row>
2589 <row>
2590 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP</constant>&nbsp;</entry>
2591 <entry>integer&nbsp;(0-255)</entry>
2592 </row><row><entry spanname="descr">Threshold below which
2593the chroma median filter is enabled (default 255)</entry>
2594 </row>
2595 <row><entry></entry></row>
2596 <row>
2597 <entry spanname="id"><constant>V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS</constant>&nbsp;</entry>
2598 <entry>boolean</entry>
2599 </row>
2600 <row><entry spanname="descr">The CX2341X MPEG encoder
2601can insert one empty MPEG-2 PES packet into the stream between every
2602four video frames. The packet size is 2048 bytes, including the
2603packet_start_code_prefix and stream_id fields. The stream_id is 0xBF
2604(private stream 2). The payload consists of 0x00 bytes, to be filled
2605in by the application. 0 = do not insert, 1 = insert packets.</entry>
2606 </row>
2607 </tbody>
2608 </tgroup>
2609 </table>
2610 </section>
2611 </section>
2612
2613 <section id="camera-controls">
2614 <title>Camera Control Reference</title>
2615
2616 <para>The Camera class includes controls for mechanical (or
2617equivalent digital) features of a device such as controllable lenses
2618or sensors.</para>
2619
2620 <table pgwide="1" frame="none" id="camera-control-id">
2621 <title>Camera Control IDs</title>
2622 <tgroup cols="4">
2623 <colspec colname="c1" colwidth="1*" />
2624 <colspec colname="c2" colwidth="6*" />
2625 <colspec colname="c3" colwidth="2*" />
2626 <colspec colname="c4" colwidth="6*" />
2627 <spanspec namest="c1" nameend="c2" spanname="id" />
2628 <spanspec namest="c2" nameend="c4" spanname="descr" />
2629 <thead>
2630 <row>
2631 <entry spanname="id" align="left">ID</entry>
2632 <entry align="left">Type</entry>
2633 </row><row rowsep="1"><entry spanname="descr" align="left">Description</entry>
2634 </row>
2635 </thead>
2636 <tbody valign="top">
2637 <row><entry></entry></row>
2638 <row>
2639 <entry spanname="id"><constant>V4L2_CID_CAMERA_CLASS</constant>&nbsp;</entry>
2640 <entry>class</entry>
2641 </row><row><entry spanname="descr">The Camera class
2642descriptor. Calling &VIDIOC-QUERYCTRL; for this control will return a
2643description of this control class.</entry>
2644 </row>
2645 <row><entry></entry></row>
2646
2647 <row id="v4l2-exposure-auto-type">
2648 <entry spanname="id"><constant>V4L2_CID_EXPOSURE_AUTO</constant>&nbsp;</entry>
2649 <entry>enum&nbsp;v4l2_exposure_auto_type</entry>
2650 </row><row><entry spanname="descr">Enables automatic
2651adjustments of the exposure time and/or iris aperture. The effect of
2652manual changes of the exposure time or iris aperture while these
2653features are enabled is undefined, drivers should ignore such
2654requests. Possible values are:</entry>
2655 </row>
2656 <row>
2657 <entrytbl spanname="descr" cols="2">
2658 <tbody valign="top">
2659 <row>
2660 <entry><constant>V4L2_EXPOSURE_AUTO</constant>&nbsp;</entry>
2661 <entry>Automatic exposure time, automatic iris
2662aperture.</entry>
2663 </row>
2664 <row>
2665 <entry><constant>V4L2_EXPOSURE_MANUAL</constant>&nbsp;</entry>
2666 <entry>Manual exposure time, manual iris.</entry>
2667 </row>
2668 <row>
2669 <entry><constant>V4L2_EXPOSURE_SHUTTER_PRIORITY</constant>&nbsp;</entry>
2670 <entry>Manual exposure time, auto iris.</entry>
2671 </row>
2672 <row>
2673 <entry><constant>V4L2_EXPOSURE_APERTURE_PRIORITY</constant>&nbsp;</entry>
2674 <entry>Auto exposure time, manual iris.</entry>
2675 </row>
2676 </tbody>
2677 </entrytbl>
2678 </row>
2679 <row><entry></entry></row>
2680
2681 <row>
2682 <entry spanname="id"><constant>V4L2_CID_EXPOSURE_ABSOLUTE</constant>&nbsp;</entry>
2683 <entry>integer</entry>
2684 </row><row><entry spanname="descr">Determines the exposure
2685time of the camera sensor. The exposure time is limited by the frame
2686interval. Drivers should interpret the values as 100 &micro;s units,
2687where the value 1 stands for 1/10000th of a second, 10000 for 1 second
2688and 100000 for 10 seconds.</entry>
2689 </row>
2690 <row><entry></entry></row>
2691
2692 <row>
2693 <entry spanname="id"><constant>V4L2_CID_EXPOSURE_AUTO_PRIORITY</constant>&nbsp;</entry>
2694 <entry>boolean</entry>
2695 </row><row><entry spanname="descr">When
2696<constant>V4L2_CID_EXPOSURE_AUTO</constant> is set to
2697<constant>AUTO</constant> or <constant>APERTURE_PRIORITY</constant>,
2698this control determines if the device may dynamically vary the frame
2699rate. By default this feature is disabled (0) and the frame rate must
2700remain constant.</entry>
2701 </row>
2702 <row><entry></entry></row>
2703
2704 <row>
2705 <entry spanname="id"><constant>V4L2_CID_PAN_RELATIVE</constant>&nbsp;</entry>
2706 <entry>integer</entry>
2707 </row><row><entry spanname="descr">This control turns the
2708camera horizontally by the specified amount. The unit is undefined. A
2709positive value moves the camera to the right (clockwise when viewed
2710from above), a negative value to the left. A value of zero does not
2711cause motion. This is a write-only control.</entry>
2712 </row>
2713 <row><entry></entry></row>
2714
2715 <row>
2716 <entry spanname="id"><constant>V4L2_CID_TILT_RELATIVE</constant>&nbsp;</entry>
2717 <entry>integer</entry>
2718 </row><row><entry spanname="descr">This control turns the
2719camera vertically by the specified amount. The unit is undefined. A
2720positive value moves the camera up, a negative value down. A value of
2721zero does not cause motion. This is a write-only control.</entry>
2722 </row>
2723 <row><entry></entry></row>
2724
2725 <row>
2726 <entry spanname="id"><constant>V4L2_CID_PAN_RESET</constant>&nbsp;</entry>
2727 <entry>button</entry>
2728 </row><row><entry spanname="descr">When this control is set,
2729the camera moves horizontally to the default position.</entry>
2730 </row>
2731 <row><entry></entry></row>
2732
2733 <row>
2734 <entry spanname="id"><constant>V4L2_CID_TILT_RESET</constant>&nbsp;</entry>
2735 <entry>button</entry>
2736 </row><row><entry spanname="descr">When this control is set,
2737the camera moves vertically to the default position.</entry>
2738 </row>
2739 <row><entry></entry></row>
2740
2741 <row>
2742 <entry spanname="id"><constant>V4L2_CID_PAN_ABSOLUTE</constant>&nbsp;</entry>
2743 <entry>integer</entry>
2744 </row><row><entry spanname="descr">This control
2745turns the camera horizontally to the specified position. Positive
2746values move the camera to the right (clockwise when viewed from above),
2747negative values to the left. Drivers should interpret the values as arc
2748seconds, with valid values between -180 * 3600 and +180 * 3600
2749inclusive.</entry>
2750 </row>
2751 <row><entry></entry></row>
2752
2753 <row>
2754 <entry spanname="id"><constant>V4L2_CID_TILT_ABSOLUTE</constant>&nbsp;</entry>
2755 <entry>integer</entry>
2756 </row><row><entry spanname="descr">This control
2757turns the camera vertically to the specified position. Positive values
2758move the camera up, negative values down. Drivers should interpret the
2759values as arc seconds, with valid values between -180 * 3600 and +180
2760* 3600 inclusive.</entry>
2761 </row>
2762 <row><entry></entry></row>
2763
2764 <row>
2765 <entry spanname="id"><constant>V4L2_CID_FOCUS_ABSOLUTE</constant>&nbsp;</entry>
2766 <entry>integer</entry>
2767 </row><row><entry spanname="descr">This control sets the
2768focal point of the camera to the specified position. The unit is
2769undefined. Positive values set the focus closer to the camera,
2770negative values towards infinity.</entry>
2771 </row>
2772 <row><entry></entry></row>
2773
2774 <row>
2775 <entry spanname="id"><constant>V4L2_CID_FOCUS_RELATIVE</constant>&nbsp;</entry>
2776 <entry>integer</entry>
2777 </row><row><entry spanname="descr">This control moves the
2778focal point of the camera by the specified amount. The unit is
2779undefined. Positive values move the focus closer to the camera,
2780negative values towards infinity. This is a write-only control.</entry>
2781 </row>
2782 <row><entry></entry></row>
2783
2784 <row>
2785 <entry spanname="id"><constant>V4L2_CID_FOCUS_AUTO</constant>&nbsp;</entry>
2786 <entry>boolean</entry>
2787 </row><row><entry spanname="descr">Enables automatic focus
2788adjustments. The effect of manual focus adjustments while this feature
2789is enabled is undefined, drivers should ignore such requests.</entry>
2790 </row>
2791 <row><entry></entry></row>
2792
2793 <row>
2794 <entry spanname="id"><constant>V4L2_CID_ZOOM_ABSOLUTE</constant>&nbsp;</entry>
2795 <entry>integer</entry>
2796 </row><row><entry spanname="descr">Specify the objective lens
2797focal length as an absolute value. The zoom unit is driver-specific and its
2798value should be a positive integer.</entry>
2799 </row>
2800 <row><entry></entry></row>
2801
2802 <row>
2803 <entry spanname="id"><constant>V4L2_CID_ZOOM_RELATIVE</constant>&nbsp;</entry>
2804 <entry>integer</entry>
2805 </row><row><entry spanname="descr">Specify the objective lens
2806focal length relatively to the current value. Positive values move the zoom
2807lens group towards the telephoto direction, negative values towards the
2808wide-angle direction. The zoom unit is driver-specific. This is a write-only control.</entry>
2809 </row>
2810 <row><entry></entry></row>
2811
2812 <row>
2813 <entry spanname="id"><constant>V4L2_CID_ZOOM_CONTINUOUS</constant>&nbsp;</entry>
2814 <entry>integer</entry>
2815 </row><row><entry spanname="descr">Move the objective lens group
2816at the specified speed until it reaches physical device limits or until an
2817explicit request to stop the movement. A positive value moves the zoom lens
2818group towards the telephoto direction. A value of zero stops the zoom lens
2819group movement. A negative value moves the zoom lens group towards the
2820wide-angle direction. The zoom speed unit is driver-specific.</entry>
2821 </row>
2822 <row><entry></entry></row>
2823
2824 <row>
Laurent Pinchart48213fe2010-01-20 12:12:57 -03002825 <entry spanname="id"><constant>V4L2_CID_IRIS_ABSOLUTE</constant>&nbsp;</entry>
2826 <entry>integer</entry>
2827 </row><row><entry spanname="descr">This control sets the
2828camera's aperture to the specified value. The unit is undefined.
2829Larger values open the iris wider, smaller values close it.</entry>
2830 </row>
2831 <row><entry></entry></row>
2832
2833 <row>
2834 <entry spanname="id"><constant>V4L2_CID_IRIS_RELATIVE</constant>&nbsp;</entry>
2835 <entry>integer</entry>
2836 </row><row><entry spanname="descr">This control modifies the
2837camera's aperture by the specified amount. The unit is undefined.
2838Positive values open the iris one step further, negative values close
2839it one step further. This is a write-only control.</entry>
2840 </row>
2841 <row><entry></entry></row>
2842
2843 <row>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03002844 <entry spanname="id"><constant>V4L2_CID_PRIVACY</constant>&nbsp;</entry>
2845 <entry>boolean</entry>
2846 </row><row><entry spanname="descr">Prevent video from being acquired
2847by the camera. When this control is set to <constant>TRUE</constant> (1), no
2848image can be captured by the camera. Common means to enforce privacy are
2849mechanical obturation of the sensor and firmware image processing, but the
2850device is not restricted to these methods. Devices that implement the privacy
2851control must support read access and may support write access.</entry>
2852 </row>
2853
2854 <row>
2855 <entry spanname="id"><constant>V4L2_CID_BAND_STOP_FILTER</constant>&nbsp;</entry>
2856 <entry>integer</entry>
2857 </row><row><entry spanname="descr">Switch the band-stop filter of a
2858camera sensor on or off, or specify its strength. Such band-stop filters can
2859be used, for example, to filter out the fluorescent light component.</entry>
2860 </row>
2861 <row><entry></entry></row>
2862 </tbody>
2863 </tgroup>
2864 </table>
2865 </section>
2866
2867 <section id="fm-tx-controls">
2868 <title>FM Transmitter Control Reference</title>
2869
2870 <para>The FM Transmitter (FM_TX) class includes controls for common features of
2871FM transmissions capable devices. Currently this class includes parameters for audio
2872compression, pilot tone generation, audio deviation limiter, RDS transmission and
2873tuning power features.</para>
2874
2875 <table pgwide="1" frame="none" id="fm-tx-control-id">
2876 <title>FM_TX Control IDs</title>
2877
2878 <tgroup cols="4">
2879 <colspec colname="c1" colwidth="1*" />
2880 <colspec colname="c2" colwidth="6*" />
2881 <colspec colname="c3" colwidth="2*" />
2882 <colspec colname="c4" colwidth="6*" />
2883 <spanspec namest="c1" nameend="c2" spanname="id" />
2884 <spanspec namest="c2" nameend="c4" spanname="descr" />
2885 <thead>
2886 <row>
2887 <entry spanname="id" align="left">ID</entry>
2888 <entry align="left">Type</entry>
2889 </row><row rowsep="1"><entry spanname="descr" align="left">Description</entry>
2890 </row>
2891 </thead>
2892 <tbody valign="top">
2893 <row><entry></entry></row>
2894 <row>
2895 <entry spanname="id"><constant>V4L2_CID_FM_TX_CLASS</constant>&nbsp;</entry>
2896 <entry>class</entry>
2897 </row><row><entry spanname="descr">The FM_TX class
2898descriptor. Calling &VIDIOC-QUERYCTRL; for this control will return a
2899description of this control class.</entry>
2900 </row>
2901 <row>
2902 <entry spanname="id"><constant>V4L2_CID_RDS_TX_DEVIATION</constant>&nbsp;</entry>
2903 <entry>integer</entry>
2904 </row>
2905 <row><entry spanname="descr">Configures RDS signal frequency deviation level in Hz.
2906The range and step are driver-specific.</entry>
2907 </row>
2908 <row>
2909 <entry spanname="id"><constant>V4L2_CID_RDS_TX_PI</constant>&nbsp;</entry>
2910 <entry>integer</entry>
2911 </row>
2912 <row><entry spanname="descr">Sets the RDS Programme Identification field
2913for transmission.</entry>
2914 </row>
2915 <row>
2916 <entry spanname="id"><constant>V4L2_CID_RDS_TX_PTY</constant>&nbsp;</entry>
2917 <entry>integer</entry>
2918 </row>
2919 <row><entry spanname="descr">Sets the RDS Programme Type field for transmission.
2920This encodes up to 31 pre-defined programme types.</entry>
2921 </row>
2922 <row>
2923 <entry spanname="id"><constant>V4L2_CID_RDS_TX_PS_NAME</constant>&nbsp;</entry>
2924 <entry>string</entry>
2925 </row>
2926 <row><entry spanname="descr">Sets the Programme Service name (PS_NAME) for transmission.
2927It is intended for static display on a receiver. It is the primary aid to listeners in programme service
2928identification and selection. In Annex E of <xref linkend="en50067" />, the RDS specification,
2929there is a full description of the correct character encoding for Programme Service name strings.
2930Also from RDS specification, PS is usually a single eight character text. However, it is also possible
2931to find receivers which can scroll strings sized as 8 x N characters. So, this control must be configured
2932with steps of 8 characters. The result is it must always contain a string with size multiple of 8.</entry>
2933 </row>
2934 <row>
2935 <entry spanname="id"><constant>V4L2_CID_RDS_TX_RADIO_TEXT</constant>&nbsp;</entry>
2936 <entry>string</entry>
2937 </row>
2938 <row><entry spanname="descr">Sets the Radio Text info for transmission. It is a textual description of
2939what is being broadcasted. RDS Radio Text can be applied when broadcaster wishes to transmit longer PS names,
2940programme-related information or any other text. In these cases, RadioText should be used in addition to
2941<constant>V4L2_CID_RDS_TX_PS_NAME</constant>. The encoding for Radio Text strings is also fully described
2942in Annex E of <xref linkend="en50067" />. The length of Radio Text strings depends on which RDS Block is being
2943used to transmit it, either 32 (2A block) or 64 (2B block). However, it is also possible
2944to find receivers which can scroll strings sized as 32 x N or 64 x N characters. So, this control must be configured
2945with steps of 32 or 64 characters. The result is it must always contain a string with size multiple of 32 or 64. </entry>
2946 </row>
2947 <row>
2948 <entry spanname="id"><constant>V4L2_CID_AUDIO_LIMITER_ENABLED</constant>&nbsp;</entry>
2949 <entry>boolean</entry>
2950 </row>
2951 <row><entry spanname="descr">Enables or disables the audio deviation limiter feature.
2952The limiter is useful when trying to maximize the audio volume, minimize receiver-generated
2953distortion and prevent overmodulation.
2954</entry>
2955 </row>
2956 <row>
2957 <entry spanname="id"><constant>V4L2_CID_AUDIO_LIMITER_RELEASE_TIME</constant>&nbsp;</entry>
2958 <entry>integer</entry>
2959 </row>
2960 <row><entry spanname="descr">Sets the audio deviation limiter feature release time.
2961Unit is in useconds. Step and range are driver-specific.</entry>
2962 </row>
2963 <row>
2964 <entry spanname="id"><constant>V4L2_CID_AUDIO_LIMITER_DEVIATION</constant>&nbsp;</entry>
2965 <entry>integer</entry>
2966 </row>
2967 <row><entry spanname="descr">Configures audio frequency deviation level in Hz.
2968The range and step are driver-specific.</entry>
2969 </row>
2970 <row>
2971 <entry spanname="id"><constant>V4L2_CID_AUDIO_COMPRESSION_ENABLED</constant>&nbsp;</entry>
2972 <entry>boolean</entry>
2973 </row>
2974 <row><entry spanname="descr">Enables or disables the audio compression feature.
2975This feature amplifies signals below the threshold by a fixed gain and compresses audio
2976signals above the threshold by the ratio of Threshold/(Gain + Threshold).</entry>
2977 </row>
2978 <row>
2979 <entry spanname="id"><constant>V4L2_CID_AUDIO_COMPRESSION_GAIN</constant>&nbsp;</entry>
2980 <entry>integer</entry>
2981 </row>
2982 <row><entry spanname="descr">Sets the gain for audio compression feature. It is
2983a dB value. The range and step are driver-specific.</entry>
2984 </row>
2985 <row>
2986 <entry spanname="id"><constant>V4L2_CID_AUDIO_COMPRESSION_THRESHOLD</constant>&nbsp;</entry>
2987 <entry>integer</entry>
2988 </row>
2989 <row><entry spanname="descr">Sets the threshold level for audio compression freature.
2990It is a dB value. The range and step are driver-specific.</entry>
2991 </row>
2992 <row>
2993 <entry spanname="id"><constant>V4L2_CID_AUDIO_COMPRESSION_ATTACK_TIME</constant>&nbsp;</entry>
2994 <entry>integer</entry>
2995 </row>
2996 <row><entry spanname="descr">Sets the attack time for audio compression feature.
2997It is a useconds value. The range and step are driver-specific.</entry>
2998 </row>
2999 <row>
3000 <entry spanname="id"><constant>V4L2_CID_AUDIO_COMPRESSION_RELEASE_TIME</constant>&nbsp;</entry>
3001 <entry>integer</entry>
3002 </row>
3003 <row><entry spanname="descr">Sets the release time for audio compression feature.
3004It is a useconds value. The range and step are driver-specific.</entry>
3005 </row>
3006 <row>
3007 <entry spanname="id"><constant>V4L2_CID_PILOT_TONE_ENABLED</constant>&nbsp;</entry>
3008 <entry>boolean</entry>
3009 </row>
3010 <row><entry spanname="descr">Enables or disables the pilot tone generation feature.</entry>
3011 </row>
3012 <row>
3013 <entry spanname="id"><constant>V4L2_CID_PILOT_TONE_DEVIATION</constant>&nbsp;</entry>
3014 <entry>integer</entry>
3015 </row>
3016 <row><entry spanname="descr">Configures pilot tone frequency deviation level. Unit is
3017in Hz. The range and step are driver-specific.</entry>
3018 </row>
3019 <row>
3020 <entry spanname="id"><constant>V4L2_CID_PILOT_TONE_FREQUENCY</constant>&nbsp;</entry>
3021 <entry>integer</entry>
3022 </row>
3023 <row><entry spanname="descr">Configures pilot tone frequency value. Unit is
3024in Hz. The range and step are driver-specific.</entry>
3025 </row>
3026 <row>
3027 <entry spanname="id"><constant>V4L2_CID_TUNE_PREEMPHASIS</constant>&nbsp;</entry>
3028 <entry>integer</entry>
3029 </row>
3030 <row id="v4l2-preemphasis"><entry spanname="descr">Configures the pre-emphasis value for broadcasting.
3031A pre-emphasis filter is applied to the broadcast to accentuate the high audio frequencies.
3032Depending on the region, a time constant of either 50 or 75 useconds is used. The enum&nbsp;v4l2_preemphasis
3033defines possible values for pre-emphasis. Here they are:</entry>
3034 </row><row>
3035 <entrytbl spanname="descr" cols="2">
3036 <tbody valign="top">
3037 <row>
3038 <entry><constant>V4L2_PREEMPHASIS_DISABLED</constant>&nbsp;</entry>
3039 <entry>No pre-emphasis is applied.</entry>
3040 </row>
3041 <row>
3042 <entry><constant>V4L2_PREEMPHASIS_50_uS</constant>&nbsp;</entry>
3043 <entry>A pre-emphasis of 50 uS is used.</entry>
3044 </row>
3045 <row>
3046 <entry><constant>V4L2_PREEMPHASIS_75_uS</constant>&nbsp;</entry>
3047 <entry>A pre-emphasis of 75 uS is used.</entry>
3048 </row>
3049 </tbody>
3050 </entrytbl>
3051
3052 </row>
3053 <row>
3054 <entry spanname="id"><constant>V4L2_CID_TUNE_POWER_LEVEL</constant>&nbsp;</entry>
3055 <entry>integer</entry>
3056 </row>
3057 <row><entry spanname="descr">Sets the output power level for signal transmission.
3058Unit is in dBuV. Range and step are driver-specific.</entry>
3059 </row>
3060 <row>
3061 <entry spanname="id"><constant>V4L2_CID_TUNE_ANTENNA_CAPACITOR</constant>&nbsp;</entry>
3062 <entry>integer</entry>
3063 </row>
3064 <row><entry spanname="descr">This selects the value of antenna tuning capacitor
3065manually or automatically if set to zero. Unit, range and step are driver-specific.</entry>
3066 </row>
3067 <row><entry></entry></row>
3068 </tbody>
3069 </tgroup>
3070 </table>
3071
3072<para>For more details about RDS specification, refer to
3073<xref linkend="en50067" /> document, from CENELEC.</para>
3074 </section>
Sakari Ailus7ba85fa2011-05-04 10:45:58 -03003075
3076 <section id="flash-controls">
3077 <title>Flash Control Reference</title>
3078
3079 <note>
3080 <title>Experimental</title>
3081
3082 <para>This is an <link linkend="experimental">experimental</link>
3083interface and may change in the future.</para>
3084 </note>
3085
3086 <para>
3087 The V4L2 flash controls are intended to provide generic access
3088 to flash controller devices. Flash controller devices are
3089 typically used in digital cameras.
3090 </para>
3091
3092 <para>
3093 The interface can support both LED and xenon flash devices. As
3094 of writing this, there is no xenon flash driver using this
3095 interface.
3096 </para>
3097
3098 <section id="flash-controls-use-cases">
3099 <title>Supported use cases</title>
3100
3101 <section>
3102 <title>Unsynchronised LED flash (software strobe)</title>
3103
3104 <para>
3105 Unsynchronised LED flash is controlled directly by the
3106 host as the sensor. The flash must be enabled by the host
3107 before the exposure of the image starts and disabled once
3108 it ends. The host is fully responsible for the timing of
3109 the flash.
3110 </para>
3111
3112 <para>Example of such device: Nokia N900.</para>
3113 </section>
3114
3115 <section>
3116 <title>Synchronised LED flash (hardware strobe)</title>
3117
3118 <para>
3119 The synchronised LED flash is pre-programmed by the host
3120 (power and timeout) but controlled by the sensor through a
3121 strobe signal from the sensor to the flash.
3122 </para>
3123
3124 <para>
3125 The sensor controls the flash duration and timing. This
3126 information typically must be made available to the
3127 sensor.
3128 </para>
3129
3130 </section>
3131
3132 <section>
3133 <title>LED flash as torch</title>
3134
3135 <para>
3136 LED flash may be used as torch in conjunction with another
3137 use case involving camera or individually.
3138 </para>
3139
3140 </section>
3141
3142 </section>
3143
3144 <table pgwide="1" frame="none" id="flash-control-id">
3145 <title>Flash Control IDs</title>
3146
3147 <tgroup cols="4">
3148 <colspec colname="c1" colwidth="1*" />
3149 <colspec colname="c2" colwidth="6*" />
3150 <colspec colname="c3" colwidth="2*" />
3151 <colspec colname="c4" colwidth="6*" />
3152 <spanspec namest="c1" nameend="c2" spanname="id" />
3153 <spanspec namest="c2" nameend="c4" spanname="descr" />
3154 <thead>
3155 <row>
3156 <entry spanname="id" align="left">ID</entry>
3157 <entry align="left">Type</entry>
3158 </row><row rowsep="1"><entry spanname="descr" align="left">Description</entry>
3159 </row>
3160 </thead>
3161 <tbody valign="top">
3162 <row><entry></entry></row>
3163 <row>
3164 <entry spanname="id"><constant>V4L2_CID_FLASH_CLASS</constant></entry>
3165 <entry>class</entry>
3166 </row>
3167 <row>
3168 <entry spanname="descr">The FLASH class descriptor.</entry>
3169 </row>
3170 <row>
3171 <entry spanname="id"><constant>V4L2_CID_FLASH_LED_MODE</constant></entry>
3172 <entry>menu</entry>
3173 </row>
3174 <row id="v4l2-flash-led-mode">
3175 <entry spanname="descr">Defines the mode of the flash LED,
3176 the high-power white LED attached to the flash controller.
3177 Setting this control may not be possible in presence of
3178 some faults. See V4L2_CID_FLASH_FAULT.</entry>
3179 </row>
3180 <row>
3181 <entrytbl spanname="descr" cols="2">
3182 <tbody valign="top">
3183 <row>
3184 <entry><constant>V4L2_FLASH_LED_MODE_NONE</constant></entry>
3185 <entry>Off.</entry>
3186 </row>
3187 <row>
3188 <entry><constant>V4L2_FLASH_LED_MODE_FLASH</constant></entry>
3189 <entry>Flash mode.</entry>
3190 </row>
3191 <row>
3192 <entry><constant>V4L2_FLASH_LED_MODE_TORCH</constant></entry>
3193 <entry>Torch mode. See V4L2_CID_FLASH_TORCH_INTENSITY.</entry>
3194 </row>
3195 </tbody>
3196 </entrytbl>
3197 </row>
3198 <row>
3199 <entry spanname="id"><constant>V4L2_CID_FLASH_STROBE_SOURCE</constant></entry>
3200 <entry>menu</entry>
3201 </row>
3202 <row id="v4l2-flash-strobe-source"><entry
3203 spanname="descr">Defines the source of the flash LED
3204 strobe.</entry>
3205 </row>
3206 <row>
3207 <entrytbl spanname="descr" cols="2">
3208 <tbody valign="top">
3209 <row>
3210 <entry><constant>V4L2_FLASH_STROBE_SOURCE_SOFTWARE</constant></entry>
3211 <entry>The flash strobe is triggered by using
3212 the V4L2_CID_FLASH_STROBE control.</entry>
3213 </row>
3214 <row>
3215 <entry><constant>V4L2_FLASH_STROBE_SOURCE_EXTERNAL</constant></entry>
3216 <entry>The flash strobe is triggered by an
3217 external source. Typically this is a sensor,
3218 which makes it possible to synchronises the
3219 flash strobe start to exposure start.</entry>
3220 </row>
3221 </tbody>
3222 </entrytbl>
3223 </row>
3224 <row>
3225 <entry spanname="id"><constant>V4L2_CID_FLASH_STROBE</constant></entry>
3226 <entry>button</entry>
3227 </row>
3228 <row>
3229 <entry spanname="descr">Strobe flash. Valid when
3230 V4L2_CID_FLASH_LED_MODE is set to
3231 V4L2_FLASH_LED_MODE_FLASH and V4L2_CID_FLASH_STROBE_SOURCE
3232 is set to V4L2_FLASH_STROBE_SOURCE_SOFTWARE. Setting this
3233 control may not be possible in presence of some faults.
3234 See V4L2_CID_FLASH_FAULT.</entry>
3235 </row>
3236 <row>
3237 <entry spanname="id"><constant>V4L2_CID_FLASH_STROBE_STOP</constant></entry>
3238 <entry>button</entry>
3239 </row>
3240 <row><entry spanname="descr">Stop flash strobe immediately.</entry>
3241 </row>
3242 <row>
3243 <entry spanname="id"><constant>V4L2_CID_FLASH_STROBE_STATUS</constant></entry>
3244 <entry>boolean</entry>
3245 </row>
3246 <row>
3247 <entry spanname="descr">Strobe status: whether the flash
3248 is strobing at the moment or not. This is a read-only
3249 control.</entry>
3250 </row>
3251 <row>
3252 <entry spanname="id"><constant>V4L2_CID_FLASH_TIMEOUT</constant></entry>
3253 <entry>integer</entry>
3254 </row>
3255 <row>
3256 <entry spanname="descr">Hardware timeout for flash. The
3257 flash strobe is stopped after this period of time has
3258 passed from the start of the strobe.</entry>
3259 </row>
3260 <row>
3261 <entry spanname="id"><constant>V4L2_CID_FLASH_INTENSITY</constant></entry>
3262 <entry>integer</entry>
3263 </row>
3264 <row>
3265 <entry spanname="descr">Intensity of the flash strobe when
3266 the flash LED is in flash mode
3267 (V4L2_FLASH_LED_MODE_FLASH). The unit should be milliamps
3268 (mA) if possible.</entry>
3269 </row>
3270 <row>
3271 <entry spanname="id"><constant>V4L2_CID_FLASH_TORCH_INTENSITY</constant></entry>
3272 <entry>integer</entry>
3273 </row>
3274 <row>
3275 <entry spanname="descr">Intensity of the flash LED in
3276 torch mode (V4L2_FLASH_LED_MODE_TORCH). The unit should be
3277 milliamps (mA) if possible. Setting this control may not
3278 be possible in presence of some faults. See
3279 V4L2_CID_FLASH_FAULT.</entry>
3280 </row>
3281 <row>
3282 <entry spanname="id"><constant>V4L2_CID_FLASH_INDICATOR_INTENSITY</constant></entry>
3283 <entry>integer</entry>
3284 </row>
3285 <row>
3286 <entry spanname="descr">Intensity of the indicator LED.
3287 The indicator LED may be fully independent of the flash
3288 LED. The unit should be microamps (uA) if possible.</entry>
3289 </row>
3290 <row>
3291 <entry spanname="id"><constant>V4L2_CID_FLASH_FAULT</constant></entry>
3292 <entry>bitmask</entry>
3293 </row>
3294 <row>
3295 <entry spanname="descr">Faults related to the flash. The
3296 faults tell about specific problems in the flash chip
3297 itself or the LEDs attached to it. Faults may prevent
3298 further use of some of the flash controls. In particular,
3299 V4L2_CID_FLASH_LED_MODE is set to V4L2_FLASH_LED_MODE_NONE
3300 if the fault affects the flash LED. Exactly which faults
3301 have such an effect is chip dependent. Reading the faults
3302 resets the control and returns the chip to a usable state
3303 if possible.</entry>
3304 </row>
3305 <row>
3306 <entrytbl spanname="descr" cols="2">
3307 <tbody valign="top">
3308 <row>
3309 <entry><constant>V4L2_FLASH_FAULT_OVER_VOLTAGE</constant></entry>
3310 <entry>Flash controller voltage to the flash LED
3311 has exceeded the limit specific to the flash
3312 controller.</entry>
3313 </row>
3314 <row>
3315 <entry><constant>V4L2_FLASH_FAULT_TIMEOUT</constant></entry>
3316 <entry>The flash strobe was still on when
3317 the timeout set by the user ---
3318 V4L2_CID_FLASH_TIMEOUT control --- has expired.
3319 Not all flash controllers may set this in all
3320 such conditions.</entry>
3321 </row>
3322 <row>
3323 <entry><constant>V4L2_FLASH_FAULT_OVER_TEMPERATURE</constant></entry>
3324 <entry>The flash controller has overheated.</entry>
3325 </row>
3326 <row>
3327 <entry><constant>V4L2_FLASH_FAULT_SHORT_CIRCUIT</constant></entry>
3328 <entry>The short circuit protection of the flash
3329 controller has been triggered.</entry>
3330 </row>
3331 </tbody>
3332 </entrytbl>
3333 </row>
3334 <row>
3335 <entry spanname="id"><constant>V4L2_CID_FLASH_CHARGE</constant></entry>
3336 <entry>boolean</entry>
3337 </row>
3338 <row><entry spanname="descr">Enable or disable charging of the xenon
3339 flash capacitor.</entry>
3340 </row>
3341 <row>
3342 <entry spanname="id"><constant>V4L2_CID_FLASH_READY</constant></entry>
3343 <entry>boolean</entry>
3344 </row>
3345 <row>
3346 <entry spanname="descr">Is the flash ready to strobe?
3347 Xenon flashes require their capacitors charged before
3348 strobing. LED flashes often require a cooldown period
3349 after strobe during which another strobe will not be
3350 possible. This is a read-only control.</entry>
3351 </row>
3352 <row><entry></entry></row>
3353 </tbody>
3354 </tgroup>
3355 </table>
3356
3357 </section>
Mauro Carvalho Chehab8e080c22009-09-13 22:16:04 -03003358</section>
3359
3360 <!--
3361Local Variables:
3362mode: sgml
3363sgml-parent-document: "common.sgml"
3364indent-tabs-mode: nil
3365End:
3366 -->