blob: 9a5704baf9fe11310c3e69cd27d26df7800d8b07 [file] [log] [blame]
Markus Heiser5377d912016-06-30 15:18:56 +02001.. -*- coding: utf-8; mode: rst -*-
2
3.. _pixfmt-reserved:
4
5***************************
6Reserved Format Identifiers
7***************************
8
9These formats are not defined by this specification, they are just
10listed for reference and to avoid naming conflicts. If you want to
11register your own format, send an e-mail to the linux-media mailing list
12`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__
13for inclusion in the ``videodev2.h`` file. If you want to share your
14format with other developers add a link to your documentation and send a
15copy to the linux-media mailing list for inclusion in this section. If
16you think your format should be listed in a standard format section
17please make a proposal on the linux-media mailing list.
18
19
20.. _reserved-formats:
21
22.. flat-table:: Reserved Image Formats
23 :header-rows: 1
24 :stub-columns: 0
25 :widths: 3 1 4
26
27
28 - .. row 1
29
30 - Identifier
31
32 - Code
33
34 - Details
35
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030036 - .. _V4L2-PIX-FMT-DV:
Markus Heiser5377d912016-06-30 15:18:56 +020037
38 - ``V4L2_PIX_FMT_DV``
39
40 - 'dvsd'
41
42 - unknown
43
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030044 - .. _V4L2-PIX-FMT-ET61X251:
Markus Heiser5377d912016-06-30 15:18:56 +020045
46 - ``V4L2_PIX_FMT_ET61X251``
47
48 - 'E625'
49
50 - Compressed format of the ET61X251 driver.
51
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030052 - .. _V4L2-PIX-FMT-HI240:
Markus Heiser5377d912016-06-30 15:18:56 +020053
54 - ``V4L2_PIX_FMT_HI240``
55
56 - 'HI24'
57
58 - 8 bit RGB format used by the BTTV driver.
59
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030060 - .. _V4L2-PIX-FMT-HM12:
Markus Heiser5377d912016-06-30 15:18:56 +020061
62 - ``V4L2_PIX_FMT_HM12``
63
64 - 'HM12'
65
66 - YUV 4:2:0 format used by the IVTV driver,
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030067 `http://www.ivtvdriver.org/ <http://www.ivtvdriver.org/>`__
Markus Heiser5377d912016-06-30 15:18:56 +020068
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030069 The format is documented in the kernel sources in the file
70 ``Documentation/video4linux/cx2341x/README.hm12``
Markus Heiser5377d912016-06-30 15:18:56 +020071
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030072 - .. _V4L2-PIX-FMT-CPIA1:
Markus Heiser5377d912016-06-30 15:18:56 +020073
74 - ``V4L2_PIX_FMT_CPIA1``
75
76 - 'CPIA'
77
78 - YUV format used by the gspca cpia1 driver.
79
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030080 - .. _V4L2-PIX-FMT-JPGL:
Markus Heiser5377d912016-06-30 15:18:56 +020081
82 - ``V4L2_PIX_FMT_JPGL``
83
84 - 'JPGL'
85
86 - JPEG-Light format (Pegasus Lossless JPEG) used in Divio webcams NW
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030087 80x.
Markus Heiser5377d912016-06-30 15:18:56 +020088
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030089 - .. _V4L2-PIX-FMT-SPCA501:
Markus Heiser5377d912016-06-30 15:18:56 +020090
91 - ``V4L2_PIX_FMT_SPCA501``
92
93 - 'S501'
94
95 - YUYV per line used by the gspca driver.
96
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -030097 - .. _V4L2-PIX-FMT-SPCA505:
Markus Heiser5377d912016-06-30 15:18:56 +020098
99 - ``V4L2_PIX_FMT_SPCA505``
100
101 - 'S505'
102
103 - YYUV per line used by the gspca driver.
104
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300105 - .. _V4L2-PIX-FMT-SPCA508:
Markus Heiser5377d912016-06-30 15:18:56 +0200106
107 - ``V4L2_PIX_FMT_SPCA508``
108
109 - 'S508'
110
111 - YUVY per line used by the gspca driver.
112
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300113 - .. _V4L2-PIX-FMT-SPCA561:
Markus Heiser5377d912016-06-30 15:18:56 +0200114
115 - ``V4L2_PIX_FMT_SPCA561``
116
117 - 'S561'
118
119 - Compressed GBRG Bayer format used by the gspca driver.
120
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300121 - .. _V4L2-PIX-FMT-PAC207:
Markus Heiser5377d912016-06-30 15:18:56 +0200122
123 - ``V4L2_PIX_FMT_PAC207``
124
125 - 'P207'
126
127 - Compressed BGGR Bayer format used by the gspca driver.
128
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300129 - .. _V4L2-PIX-FMT-MR97310A:
Markus Heiser5377d912016-06-30 15:18:56 +0200130
131 - ``V4L2_PIX_FMT_MR97310A``
132
133 - 'M310'
134
135 - Compressed BGGR Bayer format used by the gspca driver.
136
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300137 - .. _V4L2-PIX-FMT-JL2005BCD:
Markus Heiser5377d912016-06-30 15:18:56 +0200138
139 - ``V4L2_PIX_FMT_JL2005BCD``
140
141 - 'JL20'
142
143 - JPEG compressed RGGB Bayer format used by the gspca driver.
144
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300145 - .. _V4L2-PIX-FMT-OV511:
Markus Heiser5377d912016-06-30 15:18:56 +0200146
147 - ``V4L2_PIX_FMT_OV511``
148
149 - 'O511'
150
151 - OV511 JPEG format used by the gspca driver.
152
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300153 - .. _V4L2-PIX-FMT-OV518:
Markus Heiser5377d912016-06-30 15:18:56 +0200154
155 - ``V4L2_PIX_FMT_OV518``
156
157 - 'O518'
158
159 - OV518 JPEG format used by the gspca driver.
160
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300161 - .. _V4L2-PIX-FMT-PJPG:
Markus Heiser5377d912016-06-30 15:18:56 +0200162
163 - ``V4L2_PIX_FMT_PJPG``
164
165 - 'PJPG'
166
167 - Pixart 73xx JPEG format used by the gspca driver.
168
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300169 - .. _V4L2-PIX-FMT-SE401:
Markus Heiser5377d912016-06-30 15:18:56 +0200170
171 - ``V4L2_PIX_FMT_SE401``
172
173 - 'S401'
174
175 - Compressed RGB format used by the gspca se401 driver
176
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300177 - .. _V4L2-PIX-FMT-SQ905C:
Markus Heiser5377d912016-06-30 15:18:56 +0200178
179 - ``V4L2_PIX_FMT_SQ905C``
180
181 - '905C'
182
183 - Compressed RGGB bayer format used by the gspca driver.
184
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300185 - .. _V4L2-PIX-FMT-MJPEG:
Markus Heiser5377d912016-06-30 15:18:56 +0200186
187 - ``V4L2_PIX_FMT_MJPEG``
188
189 - 'MJPG'
190
191 - Compressed format used by the Zoran driver
192
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300193 - .. _V4L2-PIX-FMT-PWC1:
Markus Heiser5377d912016-06-30 15:18:56 +0200194
195 - ``V4L2_PIX_FMT_PWC1``
196
197 - 'PWC1'
198
199 - Compressed format of the PWC driver.
200
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300201 - .. _V4L2-PIX-FMT-PWC2:
Markus Heiser5377d912016-06-30 15:18:56 +0200202
203 - ``V4L2_PIX_FMT_PWC2``
204
205 - 'PWC2'
206
207 - Compressed format of the PWC driver.
208
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300209 - .. _V4L2-PIX-FMT-SN9C10X:
Markus Heiser5377d912016-06-30 15:18:56 +0200210
211 - ``V4L2_PIX_FMT_SN9C10X``
212
213 - 'S910'
214
215 - Compressed format of the SN9C102 driver.
216
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300217 - .. _V4L2-PIX-FMT-SN9C20X-I420:
Markus Heiser5377d912016-06-30 15:18:56 +0200218
219 - ``V4L2_PIX_FMT_SN9C20X_I420``
220
221 - 'S920'
222
223 - YUV 4:2:0 format of the gspca sn9c20x driver.
224
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300225 - .. _V4L2-PIX-FMT-SN9C2028:
Markus Heiser5377d912016-06-30 15:18:56 +0200226
227 - ``V4L2_PIX_FMT_SN9C2028``
228
229 - 'SONX'
230
231 - Compressed GBRG bayer format of the gspca sn9c2028 driver.
232
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300233 - .. _V4L2-PIX-FMT-STV0680:
Markus Heiser5377d912016-06-30 15:18:56 +0200234
235 - ``V4L2_PIX_FMT_STV0680``
236
237 - 'S680'
238
239 - Bayer format of the gspca stv0680 driver.
240
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300241 - .. _V4L2-PIX-FMT-WNVA:
Markus Heiser5377d912016-06-30 15:18:56 +0200242
243 - ``V4L2_PIX_FMT_WNVA``
244
245 - 'WNVA'
246
247 - Used by the Winnov Videum driver,
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300248 `http://www.thedirks.org/winnov/ <http://www.thedirks.org/winnov/>`__
Markus Heiser5377d912016-06-30 15:18:56 +0200249
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300250 - .. _V4L2-PIX-FMT-TM6000:
Markus Heiser5377d912016-06-30 15:18:56 +0200251
252 - ``V4L2_PIX_FMT_TM6000``
253
254 - 'TM60'
255
256 - Used by Trident tm6000
257
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300258 - .. _V4L2-PIX-FMT-CIT-YYVYUY:
Markus Heiser5377d912016-06-30 15:18:56 +0200259
260 - ``V4L2_PIX_FMT_CIT_YYVYUY``
261
262 - 'CITV'
263
264 - Used by xirlink CIT, found at IBM webcams.
265
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300266 Uses one line of Y then 1 line of VYUY
Markus Heiser5377d912016-06-30 15:18:56 +0200267
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300268 - .. _V4L2-PIX-FMT-KONICA420:
Markus Heiser5377d912016-06-30 15:18:56 +0200269
270 - ``V4L2_PIX_FMT_KONICA420``
271
272 - 'KONI'
273
274 - Used by Konica webcams.
275
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300276 YUV420 planar in blocks of 256 pixels.
Markus Heiser5377d912016-06-30 15:18:56 +0200277
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300278 - .. _V4L2-PIX-FMT-YYUV:
Markus Heiser5377d912016-06-30 15:18:56 +0200279
280 - ``V4L2_PIX_FMT_YYUV``
281
282 - 'YYUV'
283
284 - unknown
285
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300286 - .. _V4L2-PIX-FMT-Y4:
Markus Heiser5377d912016-06-30 15:18:56 +0200287
288 - ``V4L2_PIX_FMT_Y4``
289
290 - 'Y04 '
291
292 - Old 4-bit greyscale format. Only the most significant 4 bits of
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300293 each byte are used, the other bits are set to 0.
Markus Heiser5377d912016-06-30 15:18:56 +0200294
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300295 - .. _V4L2-PIX-FMT-Y6:
Markus Heiser5377d912016-06-30 15:18:56 +0200296
297 - ``V4L2_PIX_FMT_Y6``
298
299 - 'Y06 '
300
301 - Old 6-bit greyscale format. Only the most significant 6 bits of
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300302 each byte are used, the other bits are set to 0.
Markus Heiser5377d912016-06-30 15:18:56 +0200303
Mauro Carvalho Chehab6aeb3f62016-07-07 15:53:44 -0300304 - .. _V4L2-PIX-FMT-S5C-UYVY-JPG:
Markus Heiser5377d912016-06-30 15:18:56 +0200305
306 - ``V4L2_PIX_FMT_S5C_UYVY_JPG``
307
308 - 'S5CI'
309
310 - Two-planar format used by Samsung S5C73MX cameras. The first plane
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300311 contains interleaved JPEG and UYVY image data, followed by meta
312 data in form of an array of offsets to the UYVY data blocks. The
313 actual pointer array follows immediately the interleaved JPEG/UYVY
314 data, the number of entries in this array equals the height of the
315 UYVY image. Each entry is a 4-byte unsigned integer in big endian
316 order and it's an offset to a single pixel line of the UYVY image.
317 The first plane can start either with JPEG or UYVY data chunk. The
318 size of a single UYVY block equals the UYVY image's width
319 multiplied by 2. The size of a JPEG chunk depends on the image and
320 can vary with each line.
Markus Heiser5377d912016-06-30 15:18:56 +0200321
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300322 The second plane, at an offset of 4084 bytes, contains a 4-byte
323 offset to the pointer array in the first plane. This offset is
324 followed by a 4-byte value indicating size of the pointer array.
325 All numbers in the second plane are also in big endian order.
326 Remaining data in the second plane is undefined. The information
327 in the second plane allows to easily find location of the pointer
328 array, which can be different for each frame. The size of the
329 pointer array is constant for given UYVY image height.
Markus Heiser5377d912016-06-30 15:18:56 +0200330
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300331 In order to extract UYVY and JPEG frames an application can
332 initially set a data pointer to the start of first plane and then
333 add an offset from the first entry of the pointers table. Such a
334 pointer indicates start of an UYVY image pixel line. Whole UYVY
335 line can be copied to a separate buffer. These steps should be
336 repeated for each line, i.e. the number of entries in the pointer
337 array. Anything what's in between the UYVY lines is JPEG data and
338 should be concatenated to form the JPEG stream.
Markus Heiser5377d912016-06-30 15:18:56 +0200339
340
341
342.. _format-flags:
343
344.. flat-table:: Format Flags
345 :header-rows: 0
346 :stub-columns: 0
347 :widths: 3 1 4
348
349
350 - .. row 1
351
352 - ``V4L2_PIX_FMT_FLAG_PREMUL_ALPHA``
353
354 - 0x00000001
355
356 - The color values are premultiplied by the alpha channel value. For
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300357 example, if a light blue pixel with 50% transparency was described
358 by RGBA values (128, 192, 255, 128), the same pixel described with
359 premultiplied colors would be described by RGBA values (64, 96,
360 128, 128)