aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/DocBook/v4l/v4l2.xml
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/DocBook/v4l/v4l2.xml')
-rw-r--r--Documentation/DocBook/v4l/v4l2.xml479
1 files changed, 479 insertions, 0 deletions
diff --git a/Documentation/DocBook/v4l/v4l2.xml b/Documentation/DocBook/v4l/v4l2.xml
new file mode 100644
index 000000000000..937b4157a5d0
--- /dev/null
+++ b/Documentation/DocBook/v4l/v4l2.xml
@@ -0,0 +1,479 @@
1 <partinfo>
2 <authorgroup>
3 <author>
4 <firstname>Michael</firstname>
5 <surname>Schimek</surname>
6 <othername role="mi">H</othername>
7 <affiliation>
8 <address>
9 <email>mschimek@gmx.at</email>
10 </address>
11 </affiliation>
12 </author>
13
14 <author>
15 <firstname>Bill</firstname>
16 <surname>Dirks</surname>
17 <!-- Commented until Bill opts in to be spammed.
18 <affiliation>
19 <address>
20 <email>bill@thedirks.org</email>
21 </address>
22 </affiliation> -->
23 <contrib>Original author of the V4L2 API and
24documentation.</contrib>
25 </author>
26
27 <author>
28 <firstname>Hans</firstname>
29 <surname>Verkuil</surname>
30 <contrib>Designed and documented the VIDIOC_LOG_STATUS ioctl,
31the extended control ioctls and major parts of the sliced VBI
32API.</contrib>
33 <affiliation>
34 <address>
35 <email>hverkuil@xs4all.nl</email>
36 </address>
37 </affiliation>
38 </author>
39
40 <author>
41 <firstname>Martin</firstname>
42 <surname>Rubli</surname>
43 <!--
44 <affiliation>
45 <address>
46 <email>martin_rubli@logitech.com</email>
47 </address>
48 </affiliation> -->
49 <contrib>Designed and documented the VIDIOC_ENUM_FRAMESIZES
50and VIDIOC_ENUM_FRAMEINTERVALS ioctls.</contrib>
51 </author>
52
53 <author>
54 <firstname>Andy</firstname>
55 <surname>Walls</surname>
56 <contrib>Documented the fielded V4L2_MPEG_STREAM_VBI_FMT_IVTV
57MPEG stream embedded, sliced VBI data format in this specification.
58</contrib>
59 <affiliation>
60 <address>
61 <email>awalls@radix.net</email>
62 </address>
63 </affiliation>
64 </author>
65
66 <author>
67 <firstname>Mauro</firstname>
68 <surname>Carvalho Chehab</surname>
69 <contrib>Documented libv4l, designed and added v4l2grab example,
70Remote Controller chapter.</contrib>
71 <affiliation>
72 <address>
73 <email>mchehab@redhat.com</email>
74 </address>
75 </affiliation>
76 </author>
77 </authorgroup>
78
79 <copyright>
80 <year>1999</year>
81 <year>2000</year>
82 <year>2001</year>
83 <year>2002</year>
84 <year>2003</year>
85 <year>2004</year>
86 <year>2005</year>
87 <year>2006</year>
88 <year>2007</year>
89 <year>2008</year>
90 <year>2009</year>
91 <holder>Bill Dirks, Michael H. Schimek, Hans Verkuil, Martin
92Rubli, Andy Walls, Mauro Carvalho Chehab</holder>
93 </copyright>
94 <legalnotice>
95 <para>Except when explicitly stated as GPL, programming examples within
96 this part can be used and distributed without restrictions.</para>
97 </legalnotice>
98 <revhistory>
99 <!-- Put document revisions here, newest first. -->
100 <!-- API revisions (changes and additions of defines, enums,
101structs, ioctls) must be noted in more detail in the history chapter
102(compat.sgml), along with the possible impact on existing drivers and
103applications. -->
104
105 <revision>
106 <revnumber>2.6.32</revnumber>
107 <date>2009-08-31</date>
108 <authorinitials>mcc</authorinitials>
109 <revremark>Now, revisions will match the kernel version where
110the V4L2 API changes will be used by the Linux Kernel.
111Also added Remote Controller chapter.</revremark>
112 </revision>
113
114 <revision>
115 <revnumber>0.29</revnumber>
116 <date>2009-08-26</date>
117 <authorinitials>ev</authorinitials>
118 <revremark>Added documentation for string controls and for FM Transmitter controls.</revremark>
119 </revision>
120
121 <revision>
122 <revnumber>0.28</revnumber>
123 <date>2009-08-26</date>
124 <authorinitials>gl</authorinitials>
125 <revremark>Added V4L2_CID_BAND_STOP_FILTER documentation.</revremark>
126 </revision>
127
128 <revision>
129 <revnumber>0.27</revnumber>
130 <date>2009-08-15</date>
131 <authorinitials>mcc</authorinitials>
132 <revremark>Added libv4l and Remote Controller documentation;
133added v4l2grab and keytable application examples.</revremark>
134 </revision>
135
136 <revision>
137 <revnumber>0.26</revnumber>
138 <date>2009-07-23</date>
139 <authorinitials>hv</authorinitials>
140 <revremark>Finalized the RDS capture API. Added modulator and RDS encoder
141capabilities. Added support for string controls.</revremark>
142 </revision>
143
144 <revision>
145 <revnumber>0.25</revnumber>
146 <date>2009-01-18</date>
147 <authorinitials>hv</authorinitials>
148 <revremark>Added pixel formats VYUY, NV16 and NV61, and changed
149the debug ioctls VIDIOC_DBG_G/S_REGISTER and VIDIOC_DBG_G_CHIP_IDENT.
150Added camera controls V4L2_CID_ZOOM_ABSOLUTE, V4L2_CID_ZOOM_RELATIVE,
151V4L2_CID_ZOOM_CONTINUOUS and V4L2_CID_PRIVACY.</revremark>
152 </revision>
153
154 <revision>
155 <revnumber>0.24</revnumber>
156 <date>2008-03-04</date>
157 <authorinitials>mhs</authorinitials>
158 <revremark>Added pixel formats Y16 and SBGGR16, new controls
159and a camera controls class. Removed VIDIOC_G/S_MPEGCOMP.</revremark>
160 </revision>
161
162 <revision>
163 <revnumber>0.23</revnumber>
164 <date>2007-08-30</date>
165 <authorinitials>mhs</authorinitials>
166 <revremark>Fixed a typo in VIDIOC_DBG_G/S_REGISTER.
167Clarified the byte order of packed pixel formats.</revremark>
168 </revision>
169
170 <revision>
171 <revnumber>0.22</revnumber>
172 <date>2007-08-29</date>
173 <authorinitials>mhs</authorinitials>
174 <revremark>Added the Video Output Overlay interface, new MPEG
175controls, V4L2_FIELD_INTERLACED_TB and V4L2_FIELD_INTERLACED_BT,
176VIDIOC_DBG_G/S_REGISTER, VIDIOC_(TRY_)ENCODER_CMD,
177VIDIOC_G_CHIP_IDENT, VIDIOC_G_ENC_INDEX, new pixel formats.
178Clarifications in the cropping chapter, about RGB pixel formats, the
179mmap(), poll(), select(), read() and write() functions. Typographical
180fixes.</revremark>
181 </revision>
182
183 <revision>
184 <revnumber>0.21</revnumber>
185 <date>2006-12-19</date>
186 <authorinitials>mhs</authorinitials>
187 <revremark>Fixed a link in the VIDIOC_G_EXT_CTRLS section.</revremark>
188 </revision>
189
190 <revision>
191 <revnumber>0.20</revnumber>
192 <date>2006-11-24</date>
193 <authorinitials>mhs</authorinitials>
194 <revremark>Clarified the purpose of the audioset field in
195struct v4l2_input and v4l2_output.</revremark>
196 </revision>
197
198 <revision>
199 <revnumber>0.19</revnumber>
200 <date>2006-10-19</date>
201 <authorinitials>mhs</authorinitials>
202 <revremark>Documented V4L2_PIX_FMT_RGB444.</revremark>
203 </revision>
204
205 <revision>
206 <revnumber>0.18</revnumber>
207 <date>2006-10-18</date>
208 <authorinitials>mhs</authorinitials>
209 <revremark>Added the description of extended controls by Hans
210Verkuil. Linked V4L2_PIX_FMT_MPEG to V4L2_CID_MPEG_STREAM_TYPE.</revremark>
211 </revision>
212
213 <revision>
214 <revnumber>0.17</revnumber>
215 <date>2006-10-12</date>
216 <authorinitials>mhs</authorinitials>
217 <revremark>Corrected V4L2_PIX_FMT_HM12 description.</revremark>
218 </revision>
219
220 <revision>
221 <revnumber>0.16</revnumber>
222 <date>2006-10-08</date>
223 <authorinitials>mhs</authorinitials>
224 <revremark>VIDIOC_ENUM_FRAMESIZES and
225VIDIOC_ENUM_FRAMEINTERVALS are now part of the API.</revremark>
226 </revision>
227
228 <revision>
229 <revnumber>0.15</revnumber>
230 <date>2006-09-23</date>
231 <authorinitials>mhs</authorinitials>
232 <revremark>Cleaned up the bibliography, added BT.653 and
233BT.1119. capture.c/start_capturing() for user pointer I/O did not
234initialize the buffer index. Documented the V4L MPEG and MJPEG
235VID_TYPEs and V4L2_PIX_FMT_SBGGR8. Updated the list of reserved pixel
236formats. See the history chapter for API changes.</revremark>
237 </revision>
238
239 <revision>
240 <revnumber>0.14</revnumber>
241 <date>2006-09-14</date>
242 <authorinitials>mr</authorinitials>
243 <revremark>Added VIDIOC_ENUM_FRAMESIZES and
244VIDIOC_ENUM_FRAMEINTERVALS proposal for frame format enumeration of
245digital devices.</revremark>
246 </revision>
247
248 <revision>
249 <revnumber>0.13</revnumber>
250 <date>2006-04-07</date>
251 <authorinitials>mhs</authorinitials>
252 <revremark>Corrected the description of struct v4l2_window
253clips. New V4L2_STD_ and V4L2_TUNER_MODE_LANG1_LANG2
254defines.</revremark>
255 </revision>
256
257 <revision>
258 <revnumber>0.12</revnumber>
259 <date>2006-02-03</date>
260 <authorinitials>mhs</authorinitials>
261 <revremark>Corrected the description of struct
262v4l2_captureparm and v4l2_outputparm.</revremark>
263 </revision>
264
265 <revision>
266 <revnumber>0.11</revnumber>
267 <date>2006-01-27</date>
268 <authorinitials>mhs</authorinitials>
269 <revremark>Improved the description of struct
270v4l2_tuner.</revremark>
271 </revision>
272
273 <revision>
274 <revnumber>0.10</revnumber>
275 <date>2006-01-10</date>
276 <authorinitials>mhs</authorinitials>
277 <revremark>VIDIOC_G_INPUT and VIDIOC_S_PARM
278clarifications.</revremark>
279 </revision>
280
281 <revision>
282 <revnumber>0.9</revnumber>
283 <date>2005-11-27</date>
284 <authorinitials>mhs</authorinitials>
285 <revremark>Improved the 525 line numbering diagram. Hans
286Verkuil and I rewrote the sliced VBI section. He also contributed a
287VIDIOC_LOG_STATUS page. Fixed VIDIOC_S_STD call in the video standard
288selection example. Various updates.</revremark>
289 </revision>
290
291 <revision>
292 <revnumber>0.8</revnumber>
293 <date>2004-10-04</date>
294 <authorinitials>mhs</authorinitials>
295 <revremark>Somehow a piece of junk slipped into the capture
296example, removed.</revremark>
297 </revision>
298
299 <revision>
300 <revnumber>0.7</revnumber>
301 <date>2004-09-19</date>
302 <authorinitials>mhs</authorinitials>
303 <revremark>Fixed video standard selection, control
304enumeration, downscaling and aspect example. Added read and user
305pointer i/o to video capture example.</revremark>
306 </revision>
307
308 <revision>
309 <revnumber>0.6</revnumber>
310 <date>2004-08-01</date>
311 <authorinitials>mhs</authorinitials>
312 <revremark>v4l2_buffer changes, added video capture example,
313various corrections.</revremark>
314 </revision>
315
316 <revision>
317 <revnumber>0.5</revnumber>
318 <date>2003-11-05</date>
319 <authorinitials>mhs</authorinitials>
320 <revremark>Pixel format erratum.</revremark>
321 </revision>
322
323 <revision>
324 <revnumber>0.4</revnumber>
325 <date>2003-09-17</date>
326 <authorinitials>mhs</authorinitials>
327 <revremark>Corrected source and Makefile to generate a PDF.
328SGML fixes. Added latest API changes. Closed gaps in the history
329chapter.</revremark>
330 </revision>
331
332 <revision>
333 <revnumber>0.3</revnumber>
334 <date>2003-02-05</date>
335 <authorinitials>mhs</authorinitials>
336 <revremark>Another draft, more corrections.</revremark>
337 </revision>
338
339 <revision>
340 <revnumber>0.2</revnumber>
341 <date>2003-01-15</date>
342 <authorinitials>mhs</authorinitials>
343 <revremark>Second draft, with corrections pointed out by Gerd
344Knorr.</revremark>
345 </revision>
346
347 <revision>
348 <revnumber>0.1</revnumber>
349 <date>2002-12-01</date>
350 <authorinitials>mhs</authorinitials>
351 <revremark>First draft, based on documentation by Bill Dirks
352and discussions on the V4L mailing list.</revremark>
353 </revision>
354 </revhistory>
355</partinfo>
356
357<title>Video for Linux Two API Specification</title>
358 <subtitle>Revision 2.6.32</subtitle>
359
360 <chapter id="common">
361 &sub-common;
362 </chapter>
363
364 <chapter id="pixfmt">
365 &sub-pixfmt;
366 </chapter>
367
368 <chapter id="io">
369 &sub-io;
370 </chapter>
371
372 <chapter id="devices">
373 <title>Interfaces</title>
374
375 <section id="capture"> &sub-dev-capture; </section>
376 <section id="overlay"> &sub-dev-overlay; </section>
377 <section id="output"> &sub-dev-output; </section>
378 <section id="osd"> &sub-dev-osd; </section>
379 <section id="codec"> &sub-dev-codec; </section>
380 <section id="effect"> &sub-dev-effect; </section>
381 <section id="raw-vbi"> &sub-dev-raw-vbi; </section>
382 <section id="sliced"> &sub-dev-sliced-vbi; </section>
383 <section id="ttx"> &sub-dev-teletext; </section>
384 <section id="radio"> &sub-dev-radio; </section>
385 <section id="rds"> &sub-dev-rds; </section>
386 </chapter>
387
388 <chapter id="driver">
389 &sub-driver;
390 </chapter>
391
392 <chapter id="libv4l">
393 &sub-libv4l;
394 </chapter>
395
396 <chapter id="compat">
397 &sub-compat;
398 </chapter>
399
400 <appendix id="user-func">
401 <title>Function Reference</title>
402
403 <!-- Keep this alphabetically sorted. -->
404
405 &sub-close;
406 &sub-ioctl;
407 <!-- All ioctls go here. -->
408 &sub-cropcap;
409 &sub-dbg-g-chip-ident;
410 &sub-dbg-g-register;
411 &sub-encoder-cmd;
412 &sub-enumaudio;
413 &sub-enumaudioout;
414 &sub-enum-fmt;
415 &sub-enum-framesizes;
416 &sub-enum-frameintervals;
417 &sub-enuminput;
418 &sub-enumoutput;
419 &sub-enumstd;
420 &sub-g-audio;
421 &sub-g-audioout;
422 &sub-g-crop;
423 &sub-g-ctrl;
424 &sub-g-enc-index;
425 &sub-g-ext-ctrls;
426 &sub-g-fbuf;
427 &sub-g-fmt;
428 &sub-g-frequency;
429 &sub-g-input;
430 &sub-g-jpegcomp;
431 &sub-g-modulator;
432 &sub-g-output;
433 &sub-g-parm;
434 &sub-g-priority;
435 &sub-g-sliced-vbi-cap;
436 &sub-g-std;
437 &sub-g-tuner;
438 &sub-log-status;
439 &sub-overlay;
440 &sub-qbuf;
441 &sub-querybuf;
442 &sub-querycap;
443 &sub-queryctrl;
444 &sub-querystd;
445 &sub-reqbufs;
446 &sub-s-hw-freq-seek;
447 &sub-streamon;
448 <!-- End of ioctls. -->
449 &sub-mmap;
450 &sub-munmap;
451 &sub-open;
452 &sub-poll;
453 &sub-read;
454 &sub-select;
455 &sub-write;
456 </appendix>
457
458 <appendix id="videodev">
459 <title>Video For Linux Two Header File</title>
460 &sub-videodev2-h;
461 </appendix>
462
463 <appendix id="capture-example">
464 <title>Video Capture Example</title>
465 &sub-capture-c;
466 </appendix>
467
468 <appendix id="v4l2grab-example">
469 <title>Video Grabber example using libv4l</title>
470 <para>This program demonstrates how to grab V4L2 images in ppm format by
471using libv4l handlers. The advantage is that this grabber can potentially work
472with any V4L2 driver.</para>
473 &sub-v4l2grab-c;
474 </appendix>
475
476 &sub-media-indices;
477
478 &sub-biblio;
479