1/**
2 * Copyright (c) 2008 The Khronos Group Inc.
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining
5 * a copy of this software and associated documentation files (the
6 * "Software"), to deal in the Software without restriction, including
7 * without limitation the rights to use, copy, modify, merge, publish,
8 * distribute, sublicense, and/or sell copies of the Software, and to
9 * permit persons to whom the Software is furnished to do so, subject
10 * to the following conditions:
11 * The above copyright notice and this permission notice shall be included
12 * in all copies or substantial portions of the Software.
13 *
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
15 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
18 * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
19 * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
20 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 *
22 */
23
24/**
25 * @file OMX_IVCommon.h - OpenMax IL version 1.1.2
26 * The structures needed by Video and Image components to exchange
27 * parameters and configuration data with the components.
28 */
29#ifndef OMX_IVCommon_h
30#define OMX_IVCommon_h
31
32#ifdef __cplusplus
33extern "C" {
34#endif /* __cplusplus */
35
36/**
37 * Each OMX header must include all required header files to allow the header
38 * to compile without errors. The includes below are required for this header
39 * file to compile successfully
40 */
41
42#include "OMX_Core.h"
43
44/** @defgroup iv OpenMAX IL Imaging and Video Domain
45 * Common structures for OpenMAX IL Imaging and Video domains
46 * @{
47 */
48
49
50/**
51 * Enumeration defining possible uncompressed image/video formats.
52 *
53 * ENUMS:
54 * Unused : Placeholder value when format is N/A
55 * Monochrome : black and white
56 * 8bitRGB332 : Red 7:5, Green 4:2, Blue 1:0
57 * 12bitRGB444 : Red 11:8, Green 7:4, Blue 3:0
58 * 16bitARGB4444 : Alpha 15:12, Red 11:8, Green 7:4, Blue 3:0
59 * 16bitARGB1555 : Alpha 15, Red 14:10, Green 9:5, Blue 4:0
60 * 16bitRGB565 : Red 15:11, Green 10:5, Blue 4:0
61 * 16bitBGR565 : Blue 15:11, Green 10:5, Red 4:0
62 * 18bitRGB666 : Red 17:12, Green 11:6, Blue 5:0
63 * 18bitARGB1665 : Alpha 17, Red 16:11, Green 10:5, Blue 4:0
64 * 19bitARGB1666 : Alpha 18, Red 17:12, Green 11:6, Blue 5:0
65 * 24bitRGB888 : Red 24:16, Green 15:8, Blue 7:0
66 * 24bitBGR888 : Blue 24:16, Green 15:8, Red 7:0
67 * 24bitARGB1887 : Alpha 23, Red 22:15, Green 14:7, Blue 6:0
68 * 25bitARGB1888 : Alpha 24, Red 23:16, Green 15:8, Blue 7:0
69 * 32bitBGRA8888 : Blue 31:24, Green 23:16, Red 15:8, Alpha 7:0
70 * 32bitARGB8888 : Alpha 31:24, Red 23:16, Green 15:8, Blue 7:0
71 * YUV411Planar : U,Y are subsampled by a factor of 4 horizontally
72 * YUV411PackedPlanar : packed per payload in planar slices
73 * YUV420Planar : Three arrays Y,U,V.
74 * YUV420PackedPlanar : packed per payload in planar slices
75 * YUV420SemiPlanar : Two arrays, one is all Y, the other is U and V
76 * YUV422Planar : Three arrays Y,U,V.
77 * YUV422PackedPlanar : packed per payload in planar slices
78 * YUV422SemiPlanar : Two arrays, one is all Y, the other is U and V
79 * YCbYCr : Organized as 16bit YUYV (i.e. YCbYCr)
80 * YCrYCb : Organized as 16bit YVYU (i.e. YCrYCb)
81 * CbYCrY : Organized as 16bit UYVY (i.e. CbYCrY)
82 * CrYCbY : Organized as 16bit VYUY (i.e. CrYCbY)
83 * YUV444Interleaved : Each pixel contains equal parts YUV
84 * RawBayer8bit : SMIA camera output format
85 * RawBayer10bit : SMIA camera output format
86 * RawBayer8bitcompressed : SMIA camera output format
87 Vendor extensions
88 * 32bitABGR888 : Alpha 31:24, Blue 23:16, Green 15:8, Red 7:0
89 */
90typedef enum OMX_COLOR_FORMATTYPE {
91 OMX_COLOR_FormatUnused,
92 OMX_COLOR_FormatMonochrome,
93 OMX_COLOR_Format8bitRGB332,
94 OMX_COLOR_Format12bitRGB444,
95 OMX_COLOR_Format16bitARGB4444,
96 OMX_COLOR_Format16bitARGB1555,
97 OMX_COLOR_Format16bitRGB565,
98 OMX_COLOR_Format16bitBGR565,
99 OMX_COLOR_Format18bitRGB666,
100 OMX_COLOR_Format18bitARGB1665,
101 OMX_COLOR_Format19bitARGB1666,
102 OMX_COLOR_Format24bitRGB888,
103 OMX_COLOR_Format24bitBGR888,
104 OMX_COLOR_Format24bitARGB1887,
105 OMX_COLOR_Format25bitARGB1888,
106 OMX_COLOR_Format32bitBGRA8888,
107 OMX_COLOR_Format32bitARGB8888,
108 OMX_COLOR_FormatYUV411Planar,
109 OMX_COLOR_FormatYUV411PackedPlanar,
110 OMX_COLOR_FormatYUV420Planar,
111 OMX_COLOR_FormatYUV420PackedPlanar,
112 OMX_COLOR_FormatYUV420SemiPlanar,
113 OMX_COLOR_FormatYUV422Planar,
114 OMX_COLOR_FormatYUV422PackedPlanar,
115 OMX_COLOR_FormatYUV422SemiPlanar,
116 OMX_COLOR_FormatYCbYCr,
117 OMX_COLOR_FormatYCrYCb,
118 OMX_COLOR_FormatCbYCrY,
119 OMX_COLOR_FormatCrYCbY,
120 OMX_COLOR_FormatYUV444Interleaved,
121 OMX_COLOR_FormatRawBayer8bit,
122 OMX_COLOR_FormatRawBayer10bit,
123 OMX_COLOR_FormatRawBayer8bitcompressed,
124 OMX_COLOR_FormatL2,
125 OMX_COLOR_FormatL4,
126 OMX_COLOR_FormatL8,
127 OMX_COLOR_FormatL16,
128 OMX_COLOR_FormatL24,
129 OMX_COLOR_FormatL32,
130 OMX_COLOR_FormatYUV420PackedSemiPlanar,
131 OMX_COLOR_FormatYUV422PackedSemiPlanar,
132 OMX_COLOR_Format18BitBGR666,
133 OMX_COLOR_Format24BitARGB6666,
134 OMX_COLOR_Format24BitABGR6666,
135 OMX_COLOR_FormatKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
136 OMX_COLOR_FormatVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
137 OMX_COLOR_Format32bitABGR8888,
138 OMX_COLOR_Format8bitPalette,
139 OMX_COLOR_FormatYUVUV128,
140 OMX_COLOR_FormatRawBayer12bit,
141 OMX_COLOR_FormatBRCMEGL,
142 OMX_COLOR_FormatBRCMOpaque,
143 OMX_COLOR_FormatYVU420PackedPlanar,
144 OMX_COLOR_FormatYVU420PackedSemiPlanar,
145 OMX_COLOR_FormatRawBayer16bit,
146 OMX_COLOR_FormatYUV420_16PackedPlanar, /**< YUV420, 16bit/component */
147 OMX_COLOR_FormatYUVUV64_16, /**< YUVUV, 16bit/component */
148 OMX_COLOR_FormatYUV420_10PackedPlanar, /**< YUV420, 10bit/component as least sig 10bits of 16 bit words */
149 OMX_COLOR_FormatYUVUV64_10, /**< YUVUV, 10bit/component as least sig 10bits of 16 bit words */
150 OMX_COLOR_FormatYUV420_UVSideBySide, /**< YUV420, but with U and V in side-by-side format */
151 OMX_COLOR_Format32bitXRGB8888,
152 OMX_COLOR_Format32bitXBGR8888,
153 OMX_COLOR_FormatYUV10bitColumn,
154 OMX_COLOR_FormatMax = 0x7FFFFFFF
155} OMX_COLOR_FORMATTYPE;
156
157
158/**
159 * Defines the matrix for conversion from RGB to YUV or vice versa.
160 * iColorMatrix should be initialized with the fixed point values
161 * used in converting between formats.
162 */
163typedef struct OMX_CONFIG_COLORCONVERSIONTYPE {
164 OMX_U32 nSize; /**< Size of the structure in bytes */
165 OMX_VERSIONTYPE nVersion; /**< OMX specification version info */
166 OMX_U32 nPortIndex; /**< Port that this struct applies to */
167 OMX_S32 xColorMatrix[3][3]; /**< Stored in signed Q16 format */
168 OMX_S32 xColorOffset[4]; /**< Stored in signed Q16 format */
169}OMX_CONFIG_COLORCONVERSIONTYPE;
170
171
172/**
173 * Structure defining percent to scale each frame dimension. For example:
174 * To make the width 50% larger, use fWidth = 1.5 and to make the width
175 * 1/2 the original size, use fWidth = 0.5
176 */
177typedef struct OMX_CONFIG_SCALEFACTORTYPE {
178 OMX_U32 nSize; /**< Size of the structure in bytes */
179 OMX_VERSIONTYPE nVersion; /**< OMX specification version info */
180 OMX_U32 nPortIndex; /**< Port that this struct applies to */
181 OMX_S32 xWidth; /**< Fixed point value stored as Q16 */
182 OMX_S32 xHeight; /**< Fixed point value stored as Q16 */
183}OMX_CONFIG_SCALEFACTORTYPE;
184
185
186/**
187 * Enumeration of possible image filter types
188 */
189typedef enum OMX_IMAGEFILTERTYPE {
190 OMX_ImageFilterNone,
191 OMX_ImageFilterNoise,
192 OMX_ImageFilterEmboss,
193 OMX_ImageFilterNegative,
194 OMX_ImageFilterSketch,
195 OMX_ImageFilterOilPaint,
196 OMX_ImageFilterHatch,
197 OMX_ImageFilterGpen,
198 OMX_ImageFilterAntialias,
199 OMX_ImageFilterDeRing,
200 OMX_ImageFilterSolarize,
201 OMX_ImageFilterKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
202 OMX_ImageFilterVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
203
204 /* Broadcom specific image filters */
205 OMX_ImageFilterWatercolor,
206 OMX_ImageFilterPastel,
207 OMX_ImageFilterSharpen,
208 OMX_ImageFilterFilm,
209 OMX_ImageFilterBlur,
210 OMX_ImageFilterSaturation,
211
212 OMX_ImageFilterDeInterlaceLineDouble,
213 OMX_ImageFilterDeInterlaceAdvanced,
214
215 OMX_ImageFilterColourSwap,
216 OMX_ImageFilterWashedOut,
217 OMX_ImageFilterColourPoint,
218 OMX_ImageFilterPosterise,
219 OMX_ImageFilterColourBalance,
220 OMX_ImageFilterCartoon,
221
222 OMX_ImageFilterAnaglyph,
223 OMX_ImageFilterDeInterlaceFast,
224 OMX_ImageFilterMax = 0x7FFFFFFF
225} OMX_IMAGEFILTERTYPE;
226
227typedef enum OMX_IMAGEFILTERANAGLYPHTYPE {
228 OMX_ImageFilterAnaglyphNone,
229 OMX_ImageFilterAnaglyphSBStoRedCyan,
230 OMX_ImageFilterAnaglyphSBStoCyanRed,
231 OMX_ImageFilterAnaglyphSBStoGreenMagenta,
232 OMX_ImageFilterAnaglyphSBStoMagentaGreen,
233 OMX_ImageFilterAnaglyphTABtoRedCyan,
234 OMX_ImageFilterAnaglyphTABtoCyanRed,
235 OMX_ImageFilterAnaglyphTABtoGreenMagenta,
236 OMX_ImageFilterAnaglyphTABtoMagentaGreen,
237} OMX_IMAGEFILTERANAGLYPHTYPE;
238
239/**
240 * Image filter configuration
241 *
242 * STRUCT MEMBERS:
243 * nSize : Size of the structure in bytes
244 * nVersion : OMX specification version information
245 * nPortIndex : Port that this structure applies to
246 * eImageFilter : Image filter type enumeration
247 */
248typedef struct OMX_CONFIG_IMAGEFILTERTYPE {
249 OMX_U32 nSize;
250 OMX_VERSIONTYPE nVersion;
251 OMX_U32 nPortIndex;
252 OMX_IMAGEFILTERTYPE eImageFilter;
253} OMX_CONFIG_IMAGEFILTERTYPE;
254
255
256/**
257 * Customized U and V for color enhancement
258 *
259 * STRUCT MEMBERS:
260 * nSize : Size of the structure in bytes
261 * nVersion : OMX specification version information
262 * nPortIndex : Port that this structure applies to
263 * bColorEnhancement : Enable/disable color enhancement
264 * nCustomizedU : Practical values: 16-240, range: 0-255, value set for
265 * U component
266 * nCustomizedV : Practical values: 16-240, range: 0-255, value set for
267 * V component
268 */
269typedef struct OMX_CONFIG_COLORENHANCEMENTTYPE {
270 OMX_U32 nSize;
271 OMX_VERSIONTYPE nVersion;
272 OMX_U32 nPortIndex;
273 OMX_BOOL bColorEnhancement;
274 OMX_U8 nCustomizedU;
275 OMX_U8 nCustomizedV;
276} OMX_CONFIG_COLORENHANCEMENTTYPE;
277
278
279/**
280 * Define color key and color key mask
281 *
282 * STRUCT MEMBERS:
283 * nSize : Size of the structure in bytes
284 * nVersion : OMX specification version information
285 * nPortIndex : Port that this structure applies to
286 * nARGBColor : 32bit Alpha, Red, Green, Blue Color
287 * nARGBMask : 32bit Mask for Alpha, Red, Green, Blue channels
288 */
289typedef struct OMX_CONFIG_COLORKEYTYPE {
290 OMX_U32 nSize;
291 OMX_VERSIONTYPE nVersion;
292 OMX_U32 nPortIndex;
293 OMX_U32 nARGBColor;
294 OMX_U32 nARGBMask;
295} OMX_CONFIG_COLORKEYTYPE;
296
297
298/**
299 * List of color blend types for pre/post processing
300 *
301 * ENUMS:
302 * None : No color blending present
303 * AlphaConstant : Function is (alpha_constant * src) +
304 * (1 - alpha_constant) * dst)
305 * AlphaPerPixel : Function is (alpha * src) + (1 - alpha) * dst)
306 * Alternate : Function is alternating pixels from src and dst
307 * And : Function is (src & dst)
308 * Or : Function is (src | dst)
309 * Invert : Function is ~src
310 */
311typedef enum OMX_COLORBLENDTYPE {
312 OMX_ColorBlendNone,
313 OMX_ColorBlendAlphaConstant,
314 OMX_ColorBlendAlphaPerPixel,
315 OMX_ColorBlendAlternate,
316 OMX_ColorBlendAnd,
317 OMX_ColorBlendOr,
318 OMX_ColorBlendInvert,
319 OMX_ColorBlendKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
320 OMX_ColorBlendVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
321 OMX_ColorBlendMax = 0x7FFFFFFF
322} OMX_COLORBLENDTYPE;
323
324
325/**
326 * Color blend configuration
327 *
328 * STRUCT MEMBERS:
329 * nSize : Size of the structure in bytes
330 * nVersion : OMX specification version information
331 * nPortIndex : Port that this structure applies to
332 * nRGBAlphaConstant : Constant global alpha values when global alpha is used
333 * eColorBlend : Color blend type enumeration
334 */
335typedef struct OMX_CONFIG_COLORBLENDTYPE {
336 OMX_U32 nSize;
337 OMX_VERSIONTYPE nVersion;
338 OMX_U32 nPortIndex;
339 OMX_U32 nRGBAlphaConstant;
340 OMX_COLORBLENDTYPE eColorBlend;
341} OMX_CONFIG_COLORBLENDTYPE;
342
343
344/**
345 * Hold frame dimension
346 *
347 * STRUCT MEMBERS:
348 * nSize : Size of the structure in bytes
349 * nVersion : OMX specification version information
350 * nPortIndex : Port that this structure applies to
351 * nWidth : Frame width in pixels
352 * nHeight : Frame height in pixels
353 */
354typedef struct OMX_FRAMESIZETYPE {
355 OMX_U32 nSize;
356 OMX_VERSIONTYPE nVersion;
357 OMX_U32 nPortIndex;
358 OMX_U32 nWidth;
359 OMX_U32 nHeight;
360} OMX_FRAMESIZETYPE;
361
362
363/**
364 * Rotation configuration
365 *
366 * STRUCT MEMBERS:
367 * nSize : Size of the structure in bytes
368 * nVersion : OMX specification version information
369 * nPortIndex : Port that this structure applies to
370 * nRotation : +/- integer rotation value
371 */
372typedef struct OMX_CONFIG_ROTATIONTYPE {
373 OMX_U32 nSize;
374 OMX_VERSIONTYPE nVersion;
375 OMX_U32 nPortIndex;
376 OMX_S32 nRotation;
377} OMX_CONFIG_ROTATIONTYPE;
378
379
380/**
381 * Possible mirroring directions for pre/post processing
382 *
383 * ENUMS:
384 * None : No mirroring
385 * Vertical : Vertical mirroring, flip on X axis
386 * Horizontal : Horizontal mirroring, flip on Y axis
387 * Both : Both vertical and horizontal mirroring
388 */
389typedef enum OMX_MIRRORTYPE {
390 OMX_MirrorNone = 0,
391 OMX_MirrorVertical,
392 OMX_MirrorHorizontal,
393 OMX_MirrorBoth,
394 OMX_MirrorKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
395 OMX_MirrorVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
396 OMX_MirrorMax = 0x7FFFFFFF
397} OMX_MIRRORTYPE;
398
399
400/**
401 * Mirroring configuration
402 *
403 * STRUCT MEMBERS:
404 * nSize : Size of the structure in bytes
405 * nVersion : OMX specification version information
406 * nPortIndex : Port that this structure applies to
407 * eMirror : Mirror type enumeration
408 */
409typedef struct OMX_CONFIG_MIRRORTYPE {
410 OMX_U32 nSize;
411 OMX_VERSIONTYPE nVersion;
412 OMX_U32 nPortIndex;
413 OMX_MIRRORTYPE eMirror;
414} OMX_CONFIG_MIRRORTYPE;
415
416
417/**
418 * Position information only
419 *
420 * STRUCT MEMBERS:
421 * nSize : Size of the structure in bytes
422 * nVersion : OMX specification version information
423 * nPortIndex : Port that this structure applies to
424 * nX : X coordinate for the point
425 * nY : Y coordinate for the point
426 */
427typedef struct OMX_CONFIG_POINTTYPE {
428 OMX_U32 nSize;
429 OMX_VERSIONTYPE nVersion;
430 OMX_U32 nPortIndex;
431 OMX_S32 nX;
432 OMX_S32 nY;
433} OMX_CONFIG_POINTTYPE;
434
435
436/**
437 * Frame size plus position
438 *
439 * STRUCT MEMBERS:
440 * nSize : Size of the structure in bytes
441 * nVersion : OMX specification version information
442 * nPortIndex : Port that this structure applies to
443 * nLeft : X Coordinate of the top left corner of the rectangle
444 * nTop : Y Coordinate of the top left corner of the rectangle
445 * nWidth : Width of the rectangle
446 * nHeight : Height of the rectangle
447 */
448typedef struct OMX_CONFIG_RECTTYPE {
449 OMX_U32 nSize;
450 OMX_VERSIONTYPE nVersion;
451 OMX_U32 nPortIndex;
452 OMX_S32 nLeft;
453 OMX_S32 nTop;
454 OMX_U32 nWidth;
455 OMX_U32 nHeight;
456} OMX_CONFIG_RECTTYPE;
457
458
459/**
460 * Deblocking state; it is required to be set up before starting the codec
461 *
462 * STRUCT MEMBERS:
463 * nSize : Size of the structure in bytes
464 * nVersion : OMX specification version information
465 * nPortIndex : Port that this structure applies to
466 * bDeblocking : Enable/disable deblocking mode
467 */
468typedef struct OMX_PARAM_DEBLOCKINGTYPE {
469 OMX_U32 nSize;
470 OMX_VERSIONTYPE nVersion;
471 OMX_U32 nPortIndex;
472 OMX_BOOL bDeblocking;
473} OMX_PARAM_DEBLOCKINGTYPE;
474
475
476/**
477 * Stabilization state
478 *
479 * STRUCT MEMBERS:
480 * nSize : Size of the structure in bytes
481 * nVersion : OMX specification version information
482 * nPortIndex : Port that this structure applies to
483 * bStab : Enable/disable frame stabilization state
484 */
485typedef struct OMX_CONFIG_FRAMESTABTYPE {
486 OMX_U32 nSize;
487 OMX_VERSIONTYPE nVersion;
488 OMX_U32 nPortIndex;
489 OMX_BOOL bStab;
490} OMX_CONFIG_FRAMESTABTYPE;
491
492
493/**
494 * White Balance control type
495 *
496 * STRUCT MEMBERS:
497 * SunLight : Referenced in JSR-234
498 * Flash : Optimal for device's integrated flash
499 */
500typedef enum OMX_WHITEBALCONTROLTYPE {
501 OMX_WhiteBalControlOff = 0,
502 OMX_WhiteBalControlAuto,
503 OMX_WhiteBalControlSunLight,
504 OMX_WhiteBalControlCloudy,
505 OMX_WhiteBalControlShade,
506 OMX_WhiteBalControlTungsten,
507 OMX_WhiteBalControlFluorescent,
508 OMX_WhiteBalControlIncandescent,
509 OMX_WhiteBalControlFlash,
510 OMX_WhiteBalControlHorizon,
511 OMX_WhiteBalControlGreyWorld,
512 OMX_WhiteBalControlKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
513 OMX_WhiteBalControlVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
514 OMX_WhiteBalControlMax = 0x7FFFFFFF
515} OMX_WHITEBALCONTROLTYPE;
516
517
518/**
519 * White Balance control configuration
520 *
521 * STRUCT MEMBERS:
522 * nSize : Size of the structure in bytes
523 * nVersion : OMX specification version information
524 * nPortIndex : Port that this structure applies to
525 * eWhiteBalControl : White balance enumeration
526 */
527typedef struct OMX_CONFIG_WHITEBALCONTROLTYPE {
528 OMX_U32 nSize;
529 OMX_VERSIONTYPE nVersion;
530 OMX_U32 nPortIndex;
531 OMX_WHITEBALCONTROLTYPE eWhiteBalControl;
532} OMX_CONFIG_WHITEBALCONTROLTYPE;
533
534
535/**
536 * Exposure control type
537 */
538typedef enum OMX_EXPOSURECONTROLTYPE {
539 OMX_ExposureControlOff = 0,
540 OMX_ExposureControlAuto,
541 OMX_ExposureControlNight,
542 OMX_ExposureControlBackLight,
543 OMX_ExposureControlSpotLight,
544 OMX_ExposureControlSports,
545 OMX_ExposureControlSnow,
546 OMX_ExposureControlBeach,
547 OMX_ExposureControlLargeAperture,
548 OMX_ExposureControlSmallAperture,
549 OMX_ExposureControlKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
550 OMX_ExposureControlVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
551 OMX_ExposureControlVeryLong,
552 OMX_ExposureControlFixedFps,
553 OMX_ExposureControlNightWithPreview,
554 OMX_ExposureControlAntishake,
555 OMX_ExposureControlFireworks,
556 OMX_ExposureControlMax = 0x7FFFFFFF
557} OMX_EXPOSURECONTROLTYPE;
558
559
560/**
561 * White Balance control configuration
562 *
563 * STRUCT MEMBERS:
564 * nSize : Size of the structure in bytes
565 * nVersion : OMX specification version information
566 * nPortIndex : Port that this structure applies to
567 * eExposureControl : Exposure control enumeration
568 */
569typedef struct OMX_CONFIG_EXPOSURECONTROLTYPE {
570 OMX_U32 nSize;
571 OMX_VERSIONTYPE nVersion;
572 OMX_U32 nPortIndex;
573 OMX_EXPOSURECONTROLTYPE eExposureControl;
574} OMX_CONFIG_EXPOSURECONTROLTYPE;
575
576
577/**
578 * Defines sensor supported mode.
579 *
580 * STRUCT MEMBERS:
581 * nSize : Size of the structure in bytes
582 * nVersion : OMX specification version information
583 * nPortIndex : Port that this structure applies to
584 * nFrameRate : Single shot mode is indicated by a 0
585 * bOneShot : Enable for single shot, disable for streaming
586 * sFrameSize : Framesize
587 */
588typedef struct OMX_PARAM_SENSORMODETYPE {
589 OMX_U32 nSize;
590 OMX_VERSIONTYPE nVersion;
591 OMX_U32 nPortIndex;
592 OMX_U32 nFrameRate;
593 OMX_BOOL bOneShot;
594 OMX_FRAMESIZETYPE sFrameSize;
595} OMX_PARAM_SENSORMODETYPE;
596
597
598/**
599 * Defines contrast level
600 *
601 * STRUCT MEMBERS:
602 * nSize : Size of the structure in bytes
603 * nVersion : OMX specification version information
604 * nPortIndex : Port that this structure applies to
605 * nContrast : Values allowed for contrast -100 to 100, zero means no change
606 */
607typedef struct OMX_CONFIG_CONTRASTTYPE {
608 OMX_U32 nSize;
609 OMX_VERSIONTYPE nVersion;
610 OMX_U32 nPortIndex;
611 OMX_S32 nContrast;
612} OMX_CONFIG_CONTRASTTYPE;
613
614
615/**
616 * Defines brightness level
617 *
618 * STRUCT MEMBERS:
619 * nSize : Size of the structure in bytes
620 * nVersion : OMX specification version information
621 * nPortIndex : Port that this structure applies to
622 * nBrightness : 0-100%
623 */
624typedef struct OMX_CONFIG_BRIGHTNESSTYPE {
625 OMX_U32 nSize;
626 OMX_VERSIONTYPE nVersion;
627 OMX_U32 nPortIndex;
628 OMX_U32 nBrightness;
629} OMX_CONFIG_BRIGHTNESSTYPE;
630
631
632/**
633 * Defines backlight level configuration for a video sink, e.g. LCD panel
634 *
635 * STRUCT MEMBERS:
636 * nSize : Size of the structure in bytes
637 * nVersion : OMX specification version information
638 * nPortIndex : Port that this structure applies to
639 * nBacklight : Values allowed for backlight 0-100%
640 * nTimeout : Number of milliseconds before backlight automatically turns
641 * off. A value of 0x0 disables backight timeout
642 */
643typedef struct OMX_CONFIG_BACKLIGHTTYPE {
644 OMX_U32 nSize;
645 OMX_VERSIONTYPE nVersion;
646 OMX_U32 nPortIndex;
647 OMX_U32 nBacklight;
648 OMX_U32 nTimeout;
649} OMX_CONFIG_BACKLIGHTTYPE;
650
651
652/**
653 * Defines setting for Gamma
654 *
655 * STRUCT MEMBERS:
656 * nSize : Size of the structure in bytes
657 * nVersion : OMX specification version information
658 * nPortIndex : Port that this structure applies to
659 * nGamma : Values allowed for gamma -100 to 100, zero means no change
660 */
661typedef struct OMX_CONFIG_GAMMATYPE {
662 OMX_U32 nSize;
663 OMX_VERSIONTYPE nVersion;
664 OMX_U32 nPortIndex;
665 OMX_S32 nGamma;
666} OMX_CONFIG_GAMMATYPE;
667
668
669/**
670 * Define for setting saturation
671 *
672 * STRUCT MEMBERS:
673 * nSize : Size of the structure in bytes
674 * nVersion : OMX specification version information
675 * nPortIndex : Port that this structure applies to
676 * nSaturation : Values allowed for saturation -100 to 100, zero means
677 * no change
678 */
679typedef struct OMX_CONFIG_SATURATIONTYPE {
680 OMX_U32 nSize;
681 OMX_VERSIONTYPE nVersion;
682 OMX_U32 nPortIndex;
683 OMX_S32 nSaturation;
684} OMX_CONFIG_SATURATIONTYPE;
685
686
687/**
688 * Define for setting Lightness
689 *
690 * STRUCT MEMBERS:
691 * nSize : Size of the structure in bytes
692 * nVersion : OMX specification version information
693 * nPortIndex : Port that this structure applies to
694 * nLightness : Values allowed for lightness -100 to 100, zero means no
695 * change
696 */
697typedef struct OMX_CONFIG_LIGHTNESSTYPE {
698 OMX_U32 nSize;
699 OMX_VERSIONTYPE nVersion;
700 OMX_U32 nPortIndex;
701 OMX_S32 nLightness;
702} OMX_CONFIG_LIGHTNESSTYPE;
703
704
705/**
706 * Plane blend configuration
707 *
708 * STRUCT MEMBERS:
709 * nSize : Size of the structure in bytes
710 * nVersion : OMX specification version information
711 * nPortIndex : Index of input port associated with the plane.
712 * nDepth : Depth of the plane in relation to the screen. Higher
713 * numbered depths are "behind" lower number depths.
714 * This number defaults to the Port Index number.
715 * nAlpha : Transparency blending component for the entire plane.
716 * See blending modes for more detail.
717 */
718typedef struct OMX_CONFIG_PLANEBLENDTYPE {
719 OMX_U32 nSize;
720 OMX_VERSIONTYPE nVersion;
721 OMX_U32 nPortIndex;
722 OMX_U32 nDepth;
723 OMX_U32 nAlpha;
724} OMX_CONFIG_PLANEBLENDTYPE;
725
726
727/**
728 * Define interlace type
729 *
730 * STRUCT MEMBERS:
731 * nSize : Size of the structure in bytes
732 * nVersion : OMX specification version information
733 * nPortIndex : Port that this structure applies to
734 * bEnable : Enable control variable for this functionality
735 * (see below)
736 * nInterleavePortIndex : Index of input or output port associated with
737 * the interleaved plane.
738 * pPlanarPortIndexes[4] : Index of input or output planar ports.
739 */
740typedef struct OMX_PARAM_INTERLEAVETYPE {
741 OMX_U32 nSize;
742 OMX_VERSIONTYPE nVersion;
743 OMX_U32 nPortIndex;
744 OMX_BOOL bEnable;
745 OMX_U32 nInterleavePortIndex;
746} OMX_PARAM_INTERLEAVETYPE;
747
748
749/**
750 * Defines the picture effect used for an input picture
751 */
752typedef enum OMX_TRANSITIONEFFECTTYPE {
753 OMX_EffectNone,
754 OMX_EffectFadeFromBlack,
755 OMX_EffectFadeToBlack,
756 OMX_EffectUnspecifiedThroughConstantColor,
757 OMX_EffectDissolve,
758 OMX_EffectWipe,
759 OMX_EffectUnspecifiedMixOfTwoScenes,
760 OMX_EffectKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
761 OMX_EffectVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
762
763 OMX_EffectReverseUnspecifiedMixOfTwoScenes,
764
765#ifndef __VIDEOCORE4__
766 OMX_EffectDiagonalWipe,
767 OMX_EffectDiagonalWipeRotate,
768 OMX_EffectEllipticalWipe,
769 OMX_EffectEllipticalWipeRotate,
770 OMX_EffectInverseEllipticalWipe,
771 OMX_EffectInverseEllipticalWipeRotate,
772 OMX_EffectGlassWipe,
773 OMX_EffectGlassWipeRotate,
774 OMX_EffectWavyWipe,
775 OMX_EffectWavyWipeRotate,
776 OMX_EffectMunchingSquares,
777 OMX_EffectStripeWipe,
778 OMX_EffectStripeWipeRotate,
779
780 OMX_EffectRotozoomUnmatched,
781 OMX_EffectRotozoomMatched,
782 OMX_EffectRotozoomGentle,
783#endif
784
785 OMX_EffectMunchRandom,
786 OMX_EffectMunchVRandom,
787 OMX_EffectMunchHRandom,
788 OMX_EffectMunchWipe,
789 OMX_EffectMunchMunch,
790 OMX_EffectMunchStripe,
791 OMX_EffectFadeRandom,
792 OMX_EffectFadeVRandom,
793 OMX_EffectFadeHRandom,
794 OMX_EffectFadeWipe,
795 OMX_EffectFadeMunch,
796 OMX_EffectFadeStripe,
797 OMX_EffectColourBlockRandom,
798 OMX_EffectColourBlockVRandom,
799 OMX_EffectColourBlockHRandom,
800 OMX_EffectColourBlockWipe,
801 OMX_EffectColourBlockMunch,
802 OMX_EffectColourBlockStripe,
803 OMX_EffectColourBlock2Random,
804 OMX_EffectColourBlock2VRandom,
805 OMX_EffectColourBlock2HRandom,
806 OMX_EffectColourBlock2Wipe,
807 OMX_EffectColourBlock2Munch,
808 OMX_EffectColourBlock2Stripe,
809 OMX_EffectShadeRandom,
810 OMX_EffectShadeVRandom,
811 OMX_EffectShadeHRandom,
812 OMX_EffectShadeWipe,
813 OMX_EffectShadeMunch,
814 OMX_EffectShadeStripe,
815 OMX_EffectBitmaskRandom,
816 OMX_EffectBitmaskVRandom,
817 OMX_EffectBitmaskHRandom,
818 OMX_EffectBitmaskWipe,
819 OMX_EffectBitmaskMunch,
820 OMX_EffectBitmaskStripe,
821 OMX_EffectBitmask2Random,
822 OMX_EffectBitmask2VRandom,
823 OMX_EffectBitmask2HRandom,
824 OMX_EffectBitmask2Wipe,
825 OMX_EffectBitmask2Munch,
826 OMX_EffectBitmask2Stripe,
827 OMX_EffectBitmask2ColourRandom,
828 OMX_EffectBitmask2ColourVRandom,
829 OMX_EffectBitmask2ColourHRandom,
830 OMX_EffectBitmask2ColourWipe,
831 OMX_EffectBitmask2ColourMunch,
832 OMX_EffectBitmask2ColourStripe,
833
834 OMX_EffectPushRight,
835 OMX_EffectPushLeft,
836 OMX_EffectPushDown,
837 OMX_EffectPushUp,
838 OMX_EffectCoverRight,
839 OMX_EffectCoverLeft,
840 OMX_EffectCoverDown,
841 OMX_EffectCoverUp,
842 OMX_EffectRevealRight,
843 OMX_EffectRevealLeft,
844 OMX_EffectRevealDown,
845 OMX_EffectRevealUp,
846 OMX_EffectWipeRight,
847 OMX_EffectWipeLeft,
848 OMX_EffectWipeDown,
849 OMX_EffectWipeUp,
850 OMX_EffectSpeckle,
851 OMX_EffectCircle,
852 OMX_EffectSpiral,
853 OMX_EffectDiamond,
854 OMX_EffectVert,
855 OMX_EffectPlus,
856 OMX_EffectClock,
857 OMX_EffectPlasma,
858 OMX_EffectDisplace,
859 OMX_EffectGenie,
860 OMX_EffectSide,
861 OMX_EffectMaze,
862 OMX_EffectRipple,
863 OMX_EffectStar,
864 OMX_EffectAlpha,
865 OMX_EffectIntense,
866 OMX_EffectIntenseU,
867 OMX_EffectIntenseV,
868 OMX_EffectInverseIntense,
869 OMX_EffectInverseIntenseU,
870 OMX_EffectInverseIntenseV,
871
872 OMX_EffectPageTurn,
873
874 OMX_EffectFlipPlaneDown,
875 OMX_EffectFlipPlaneDownMid,
876 OMX_EffectFlipPlaneDownHigh,
877 OMX_EffectFlipPlaneLeft,
878 OMX_EffectFlipPlaneLeftMid,
879 OMX_EffectFlipPlaneLeftHigh,
880 OMX_EffectFlipCubeDown,
881 OMX_EffectFlipCubeDownMid,
882 OMX_EffectFlipCubeDownHigh,
883 OMX_EffectFlipCubeLeft,
884 OMX_EffectFlipCubeLeftMid,
885 OMX_EffectFlipCubeLeftHigh,
886
887 OMX_EffectMax = 0x7FFFFFFF
888} OMX_TRANSITIONEFFECTTYPE;
889
890
891/**
892 * Structure used to configure current transition effect
893 *
894 * STRUCT MEMBERS:
895 * nSize : Size of the structure in bytes
896 * nVersion : OMX specification version information
897 * nPortIndex : Port that this structure applies to
898 * eEffect : Effect to enable
899 */
900typedef struct OMX_CONFIG_TRANSITIONEFFECTTYPE {
901 OMX_U32 nSize;
902 OMX_VERSIONTYPE nVersion;
903 OMX_U32 nPortIndex;
904 OMX_TRANSITIONEFFECTTYPE eEffect;
905} OMX_CONFIG_TRANSITIONEFFECTTYPE;
906
907
908/**
909 * Defines possible data unit types for encoded video data. The data unit
910 * types are used both for encoded video input for playback as well as
911 * encoded video output from recording.
912 */
913typedef enum OMX_DATAUNITTYPE {
914 OMX_DataUnitCodedPicture,
915 OMX_DataUnitVideoSegment,
916 OMX_DataUnitSeveralSegments,
917 OMX_DataUnitArbitraryStreamSection,
918 OMX_DataUnitKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
919 OMX_DataUnitVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
920 OMX_DataUnitMax = 0x7FFFFFFF
921} OMX_DATAUNITTYPE;
922
923
924/**
925 * Defines possible encapsulation types for coded video data unit. The
926 * encapsulation information is used both for encoded video input for
927 * playback as well as encoded video output from recording.
928 */
929typedef enum OMX_DATAUNITENCAPSULATIONTYPE {
930 OMX_DataEncapsulationElementaryStream,
931 OMX_DataEncapsulationGenericPayload,
932 OMX_DataEncapsulationRtpPayload,
933 OMX_DataEncapsulationKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
934 OMX_DataEncapsulationVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
935 OMX_DataEncapsulationMax = 0x7FFFFFFF
936} OMX_DATAUNITENCAPSULATIONTYPE;
937
938
939/**
940 * Structure used to configure the type of being decoded/encoded
941 */
942typedef struct OMX_PARAM_DATAUNITTYPE {
943 OMX_U32 nSize; /**< Size of the structure in bytes */
944 OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
945 OMX_U32 nPortIndex; /**< Port that this structure applies to */
946 OMX_DATAUNITTYPE eUnitType;
947 OMX_DATAUNITENCAPSULATIONTYPE eEncapsulationType;
948} OMX_PARAM_DATAUNITTYPE;
949
950
951/**
952 * Defines dither types
953 */
954typedef enum OMX_DITHERTYPE {
955 OMX_DitherNone,
956 OMX_DitherOrdered,
957 OMX_DitherErrorDiffusion,
958 OMX_DitherOther,
959 OMX_DitherKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
960 OMX_DitherVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
961 OMX_DitherMax = 0x7FFFFFFF
962} OMX_DITHERTYPE;
963
964
965/**
966 * Structure used to configure current type of dithering
967 */
968typedef struct OMX_CONFIG_DITHERTYPE {
969 OMX_U32 nSize; /**< Size of the structure in bytes */
970 OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
971 OMX_U32 nPortIndex; /**< Port that this structure applies to */
972 OMX_DITHERTYPE eDither; /**< Type of dithering to use */
973} OMX_CONFIG_DITHERTYPE;
974
975typedef struct OMX_CONFIG_CAPTUREMODETYPE {
976 OMX_U32 nSize;
977 OMX_VERSIONTYPE nVersion;
978 OMX_U32 nPortIndex; /**< Port that this structure applies to */
979 OMX_BOOL bContinuous; /**< If true then ignore frame rate and emit capture
980 * data as fast as possible (otherwise obey port's frame rate). */
981 OMX_BOOL bFrameLimited; /**< If true then terminate capture after the port emits the
982 * specified number of frames (otherwise the port does not
983 * terminate the capture until instructed to do so by the client).
984 * Even if set, the client may manually terminate the capture prior
985 * to reaching the limit. */
986 OMX_U32 nFrameLimit; /**< Limit on number of frames emitted during a capture (only
987 * valid if bFrameLimited is set). */
988} OMX_CONFIG_CAPTUREMODETYPE;
989
990typedef enum OMX_METERINGTYPE {
991
992 OMX_MeteringModeAverage, /**< Center-weighted average metering. */
993 OMX_MeteringModeSpot, /**< Spot (partial) metering. */
994 OMX_MeteringModeMatrix, /**< Matrix or evaluative metering. */
995
996 OMX_MeteringKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
997 OMX_MeteringVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
998 OMX_MeteringModeBacklit,
999 OMX_EVModeMax = 0x7fffffff
1000} OMX_METERINGTYPE;
1001
1002typedef struct OMX_CONFIG_EXPOSUREVALUETYPE {
1003 OMX_U32 nSize;
1004 OMX_VERSIONTYPE nVersion;
1005 OMX_U32 nPortIndex;
1006 OMX_METERINGTYPE eMetering;
1007 OMX_S32 xEVCompensation; /**< Fixed point value stored as Q16 */
1008 OMX_U32 nApertureFNumber; /**< e.g. nApertureFNumber = 2 implies "f/2" - Q16 format */
1009 OMX_BOOL bAutoAperture; /**< Whether aperture number is defined automatically */
1010 OMX_U32 nShutterSpeedMsec; /**< Shutterspeed in milliseconds */
1011 OMX_BOOL bAutoShutterSpeed; /**< Whether shutter speed is defined automatically */
1012 OMX_U32 nSensitivity; /**< e.g. nSensitivity = 100 implies "ISO 100" */
1013 OMX_BOOL bAutoSensitivity; /**< Whether sensitivity is defined automatically */
1014} OMX_CONFIG_EXPOSUREVALUETYPE;
1015
1016/**
1017 * Focus region configuration
1018 *
1019 * STRUCT MEMBERS:
1020 * nSize : Size of the structure in bytes
1021 * nVersion : OMX specification version information
1022 * nPortIndex : Port that this structure applies to
1023 * bCenter : Use center region as focus region of interest
1024 * bLeft : Use left region as focus region of interest
1025 * bRight : Use right region as focus region of interest
1026 * bTop : Use top region as focus region of interest
1027 * bBottom : Use bottom region as focus region of interest
1028 * bTopLeft : Use top left region as focus region of interest
1029 * bTopRight : Use top right region as focus region of interest
1030 * bBottomLeft : Use bottom left region as focus region of interest
1031 * bBottomRight : Use bottom right region as focus region of interest
1032 */
1033typedef struct OMX_CONFIG_FOCUSREGIONTYPE {
1034 OMX_U32 nSize;
1035 OMX_VERSIONTYPE nVersion;
1036 OMX_U32 nPortIndex;
1037 OMX_BOOL bCenter;
1038 OMX_BOOL bLeft;
1039 OMX_BOOL bRight;
1040 OMX_BOOL bTop;
1041 OMX_BOOL bBottom;
1042 OMX_BOOL bTopLeft;
1043 OMX_BOOL bTopRight;
1044 OMX_BOOL bBottomLeft;
1045 OMX_BOOL bBottomRight;
1046} OMX_CONFIG_FOCUSREGIONTYPE;
1047
1048/**
1049 * Focus Status type
1050 */
1051typedef enum OMX_FOCUSSTATUSTYPE {
1052 OMX_FocusStatusOff = 0,
1053 OMX_FocusStatusRequest,
1054 OMX_FocusStatusReached,
1055 OMX_FocusStatusUnableToReach,
1056 OMX_FocusStatusLost,
1057 OMX_FocusStatusKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
1058 OMX_FocusStatusVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
1059 OMX_FocusStatusCafWatching,
1060 OMX_FocusStatusCafSceneChanged,
1061 OMX_FocusStatusMax = 0x7FFFFFFF
1062} OMX_FOCUSSTATUSTYPE;
1063
1064/**
1065 * Focus status configuration
1066 *
1067 * STRUCT MEMBERS:
1068 * nSize : Size of the structure in bytes
1069 * nVersion : OMX specification version information
1070 * nPortIndex : Port that this structure applies to
1071 * eFocusStatus : Specifies the focus status
1072 * bCenterStatus : Use center region as focus region of interest
1073 * bLeftStatus : Use left region as focus region of interest
1074 * bRightStatus : Use right region as focus region of interest
1075 * bTopStatus : Use top region as focus region of interest
1076 * bBottomStatus : Use bottom region as focus region of interest
1077 * bTopLeftStatus : Use top left region as focus region of interest
1078 * bTopRightStatus : Use top right region as focus region of interest
1079 * bBottomLeftStatus : Use bottom left region as focus region of interest
1080 * bBottomRightStatus : Use bottom right region as focus region of interest
1081 */
1082typedef struct OMX_PARAM_FOCUSSTATUSTYPE {
1083 OMX_U32 nSize;
1084 OMX_VERSIONTYPE nVersion;
1085 OMX_U32 nPortIndex;
1086 OMX_FOCUSSTATUSTYPE eFocusStatus;
1087 OMX_BOOL bCenterStatus;
1088 OMX_BOOL bLeftStatus;
1089 OMX_BOOL bRightStatus;
1090 OMX_BOOL bTopStatus;
1091 OMX_BOOL bBottomStatus;
1092 OMX_BOOL bTopLeftStatus;
1093 OMX_BOOL bTopRightStatus;
1094 OMX_BOOL bBottomLeftStatus;
1095 OMX_BOOL bBottomRightStatus;
1096} OMX_PARAM_FOCUSSTATUSTYPE;
1097
1098/** @} */
1099
1100#ifdef __cplusplus
1101}
1102#endif /* __cplusplus */
1103
1104#endif
1105/* File EOF */
1106