OMX_IVCommon.h 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921
  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. * @file OMX_IVCommon.h - OpenMax IL version 1.1.2
  25. * The structures needed by Video and Image components to exchange
  26. * parameters and configuration data with the components.
  27. */
  28. #ifndef OMX_IVCommon_h
  29. #define OMX_IVCommon_h
  30. #ifdef __cplusplus
  31. extern "C" {
  32. #endif /* __cplusplus */
  33. /**
  34. * Each OMX header must include all required header files to allow the header
  35. * to compile without errors. The includes below are required for this header
  36. * file to compile successfully
  37. */
  38. #include <OMX_Core.h>
  39. /** @defgroup iv OpenMAX IL Imaging and Video Domain
  40. * Common structures for OpenMAX IL Imaging and Video domains
  41. * @{
  42. */
  43. /**
  44. * Enumeration defining possible uncompressed image/video formats.
  45. *
  46. * ENUMS:
  47. * Unused : Placeholder value when format is N/A
  48. * Monochrome : black and white
  49. * 8bitRGB332 : Red 7:5, Green 4:2, Blue 1:0
  50. * 12bitRGB444 : Red 11:8, Green 7:4, Blue 3:0
  51. * 16bitARGB4444 : Alpha 15:12, Red 11:8, Green 7:4, Blue 3:0
  52. * 16bitARGB1555 : Alpha 15, Red 14:10, Green 9:5, Blue 4:0
  53. * 16bitRGB565 : Red 15:11, Green 10:5, Blue 4:0
  54. * 16bitBGR565 : Blue 15:11, Green 10:5, Red 4:0
  55. * 18bitRGB666 : Red 17:12, Green 11:6, Blue 5:0
  56. * 18bitARGB1665 : Alpha 17, Red 16:11, Green 10:5, Blue 4:0
  57. * 19bitARGB1666 : Alpha 18, Red 17:12, Green 11:6, Blue 5:0
  58. * 24bitRGB888 : Red 24:16, Green 15:8, Blue 7:0
  59. * 24bitBGR888 : Blue 24:16, Green 15:8, Red 7:0
  60. * 24bitARGB1887 : Alpha 23, Red 22:15, Green 14:7, Blue 6:0
  61. * 25bitARGB1888 : Alpha 24, Red 23:16, Green 15:8, Blue 7:0
  62. * 32bitBGRA8888 : Blue 31:24, Green 23:16, Red 15:8, Alpha 7:0
  63. * 32bitARGB8888 : Alpha 31:24, Red 23:16, Green 15:8, Blue 7:0
  64. * YUV411Planar : U,Y are subsampled by a factor of 4 horizontally
  65. * YUV411PackedPlanar : packed per payload in planar slices
  66. * YUV420Planar : Three arrays Y,U,V.
  67. * YUV420PackedPlanar : packed per payload in planar slices
  68. * YUV420SemiPlanar : Two arrays, one is all Y, the other is U and V
  69. * YUV422Planar : Three arrays Y,U,V.
  70. * YUV422PackedPlanar : packed per payload in planar slices
  71. * YUV422SemiPlanar : Two arrays, one is all Y, the other is U and V
  72. * YCbYCr : Organized as 16bit YUYV (i.e. YCbYCr)
  73. * YCrYCb : Organized as 16bit YVYU (i.e. YCrYCb)
  74. * CbYCrY : Organized as 16bit UYVY (i.e. CbYCrY)
  75. * CrYCbY : Organized as 16bit VYUY (i.e. CrYCbY)
  76. * YUV444Interleaved : Each pixel contains equal parts YUV
  77. * RawBayer8bit : SMIA camera output format
  78. * RawBayer10bit : SMIA camera output format
  79. * RawBayer8bitcompressed : SMIA camera output format
  80. */
  81. typedef enum OMX_COLOR_FORMATTYPE {
  82. OMX_COLOR_FormatUnused,
  83. OMX_COLOR_FormatMonochrome,
  84. OMX_COLOR_Format8bitRGB332,
  85. OMX_COLOR_Format12bitRGB444,
  86. OMX_COLOR_Format16bitARGB4444,
  87. OMX_COLOR_Format16bitARGB1555,
  88. OMX_COLOR_Format16bitRGB565,
  89. OMX_COLOR_Format16bitBGR565,
  90. OMX_COLOR_Format18bitRGB666,
  91. OMX_COLOR_Format18bitARGB1665,
  92. OMX_COLOR_Format19bitARGB1666,
  93. OMX_COLOR_Format24bitRGB888,
  94. OMX_COLOR_Format24bitBGR888,
  95. OMX_COLOR_Format24bitARGB1887,
  96. OMX_COLOR_Format25bitARGB1888,
  97. OMX_COLOR_Format32bitBGRA8888,
  98. OMX_COLOR_Format32bitARGB8888,
  99. OMX_COLOR_FormatYUV411Planar,
  100. OMX_COLOR_FormatYUV411PackedPlanar,
  101. OMX_COLOR_FormatYUV420Planar,
  102. OMX_COLOR_FormatYUV420PackedPlanar,
  103. OMX_COLOR_FormatYUV420SemiPlanar,
  104. OMX_COLOR_FormatYUV422Planar,
  105. OMX_COLOR_FormatYUV422PackedPlanar,
  106. OMX_COLOR_FormatYUV422SemiPlanar,
  107. OMX_COLOR_FormatYCbYCr,
  108. OMX_COLOR_FormatYCrYCb,
  109. OMX_COLOR_FormatCbYCrY,
  110. OMX_COLOR_FormatCrYCbY,
  111. OMX_COLOR_FormatYUV444Interleaved,
  112. OMX_COLOR_FormatRawBayer8bit,
  113. OMX_COLOR_FormatRawBayer10bit,
  114. OMX_COLOR_FormatRawBayer8bitcompressed,
  115. OMX_COLOR_FormatL2,
  116. OMX_COLOR_FormatL4,
  117. OMX_COLOR_FormatL8,
  118. OMX_COLOR_FormatL16,
  119. OMX_COLOR_FormatL24,
  120. OMX_COLOR_FormatL32,
  121. OMX_COLOR_FormatYUV420PackedSemiPlanar,
  122. OMX_COLOR_FormatYUV422PackedSemiPlanar,
  123. OMX_COLOR_Format18BitBGR666,
  124. OMX_COLOR_Format24BitARGB6666,
  125. OMX_COLOR_Format24BitABGR6666,
  126. OMX_COLOR_FormatKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  127. OMX_COLOR_FormatVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  128. OMX_COLOR_FormatMax = 0x7FFFFFFF
  129. } OMX_COLOR_FORMATTYPE;
  130. /**
  131. * Defines the matrix for conversion from RGB to YUV or vice versa.
  132. * iColorMatrix should be initialized with the fixed point values
  133. * used in converting between formats.
  134. */
  135. typedef struct OMX_CONFIG_COLORCONVERSIONTYPE {
  136. OMX_U32 nSize; /**< Size of the structure in bytes */
  137. OMX_VERSIONTYPE nVersion; /**< OMX specification version info */
  138. OMX_U32 nPortIndex; /**< Port that this struct applies to */
  139. OMX_S32 xColorMatrix[3][3]; /**< Stored in signed Q16 format */
  140. OMX_S32 xColorOffset[4]; /**< Stored in signed Q16 format */
  141. }OMX_CONFIG_COLORCONVERSIONTYPE;
  142. /**
  143. * Structure defining percent to scale each frame dimension. For example:
  144. * To make the width 50% larger, use fWidth = 1.5 and to make the width
  145. * 1/2 the original size, use fWidth = 0.5
  146. */
  147. typedef struct OMX_CONFIG_SCALEFACTORTYPE {
  148. OMX_U32 nSize; /**< Size of the structure in bytes */
  149. OMX_VERSIONTYPE nVersion; /**< OMX specification version info */
  150. OMX_U32 nPortIndex; /**< Port that this struct applies to */
  151. OMX_S32 xWidth; /**< Fixed point value stored as Q16 */
  152. OMX_S32 xHeight; /**< Fixed point value stored as Q16 */
  153. }OMX_CONFIG_SCALEFACTORTYPE;
  154. /**
  155. * Enumeration of possible image filter types
  156. */
  157. typedef enum OMX_IMAGEFILTERTYPE {
  158. OMX_ImageFilterNone,
  159. OMX_ImageFilterNoise,
  160. OMX_ImageFilterEmboss,
  161. OMX_ImageFilterNegative,
  162. OMX_ImageFilterSketch,
  163. OMX_ImageFilterOilPaint,
  164. OMX_ImageFilterHatch,
  165. OMX_ImageFilterGpen,
  166. OMX_ImageFilterAntialias,
  167. OMX_ImageFilterDeRing,
  168. OMX_ImageFilterSolarize,
  169. OMX_ImageFilterKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  170. OMX_ImageFilterVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  171. OMX_ImageFilterMax = 0x7FFFFFFF
  172. } OMX_IMAGEFILTERTYPE;
  173. /**
  174. * Image filter configuration
  175. *
  176. * STRUCT MEMBERS:
  177. * nSize : Size of the structure in bytes
  178. * nVersion : OMX specification version information
  179. * nPortIndex : Port that this structure applies to
  180. * eImageFilter : Image filter type enumeration
  181. */
  182. typedef struct OMX_CONFIG_IMAGEFILTERTYPE {
  183. OMX_U32 nSize;
  184. OMX_VERSIONTYPE nVersion;
  185. OMX_U32 nPortIndex;
  186. OMX_IMAGEFILTERTYPE eImageFilter;
  187. } OMX_CONFIG_IMAGEFILTERTYPE;
  188. /**
  189. * Customized U and V for color enhancement
  190. *
  191. * STRUCT MEMBERS:
  192. * nSize : Size of the structure in bytes
  193. * nVersion : OMX specification version information
  194. * nPortIndex : Port that this structure applies to
  195. * bColorEnhancement : Enable/disable color enhancement
  196. * nCustomizedU : Practical values: 16-240, range: 0-255, value set for
  197. * U component
  198. * nCustomizedV : Practical values: 16-240, range: 0-255, value set for
  199. * V component
  200. */
  201. typedef struct OMX_CONFIG_COLORENHANCEMENTTYPE {
  202. OMX_U32 nSize;
  203. OMX_VERSIONTYPE nVersion;
  204. OMX_U32 nPortIndex;
  205. OMX_BOOL bColorEnhancement;
  206. OMX_U8 nCustomizedU;
  207. OMX_U8 nCustomizedV;
  208. } OMX_CONFIG_COLORENHANCEMENTTYPE;
  209. /**
  210. * Define color key and color key mask
  211. *
  212. * STRUCT MEMBERS:
  213. * nSize : Size of the structure in bytes
  214. * nVersion : OMX specification version information
  215. * nPortIndex : Port that this structure applies to
  216. * nARGBColor : 32bit Alpha, Red, Green, Blue Color
  217. * nARGBMask : 32bit Mask for Alpha, Red, Green, Blue channels
  218. */
  219. typedef struct OMX_CONFIG_COLORKEYTYPE {
  220. OMX_U32 nSize;
  221. OMX_VERSIONTYPE nVersion;
  222. OMX_U32 nPortIndex;
  223. OMX_U32 nARGBColor;
  224. OMX_U32 nARGBMask;
  225. } OMX_CONFIG_COLORKEYTYPE;
  226. /**
  227. * List of color blend types for pre/post processing
  228. *
  229. * ENUMS:
  230. * None : No color blending present
  231. * AlphaConstant : Function is (alpha_constant * src) +
  232. * (1 - alpha_constant) * dst)
  233. * AlphaPerPixel : Function is (alpha * src) + (1 - alpha) * dst)
  234. * Alternate : Function is alternating pixels from src and dst
  235. * And : Function is (src & dst)
  236. * Or : Function is (src | dst)
  237. * Invert : Function is ~src
  238. */
  239. typedef enum OMX_COLORBLENDTYPE {
  240. OMX_ColorBlendNone,
  241. OMX_ColorBlendAlphaConstant,
  242. OMX_ColorBlendAlphaPerPixel,
  243. OMX_ColorBlendAlternate,
  244. OMX_ColorBlendAnd,
  245. OMX_ColorBlendOr,
  246. OMX_ColorBlendInvert,
  247. OMX_ColorBlendKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  248. OMX_ColorBlendVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  249. OMX_ColorBlendMax = 0x7FFFFFFF
  250. } OMX_COLORBLENDTYPE;
  251. /**
  252. * Color blend configuration
  253. *
  254. * STRUCT MEMBERS:
  255. * nSize : Size of the structure in bytes
  256. * nVersion : OMX specification version information
  257. * nPortIndex : Port that this structure applies to
  258. * nRGBAlphaConstant : Constant global alpha values when global alpha is used
  259. * eColorBlend : Color blend type enumeration
  260. */
  261. typedef struct OMX_CONFIG_COLORBLENDTYPE {
  262. OMX_U32 nSize;
  263. OMX_VERSIONTYPE nVersion;
  264. OMX_U32 nPortIndex;
  265. OMX_U32 nRGBAlphaConstant;
  266. OMX_COLORBLENDTYPE eColorBlend;
  267. } OMX_CONFIG_COLORBLENDTYPE;
  268. /**
  269. * Hold frame dimension
  270. *
  271. * STRUCT MEMBERS:
  272. * nSize : Size of the structure in bytes
  273. * nVersion : OMX specification version information
  274. * nPortIndex : Port that this structure applies to
  275. * nWidth : Frame width in pixels
  276. * nHeight : Frame height in pixels
  277. */
  278. typedef struct OMX_FRAMESIZETYPE {
  279. OMX_U32 nSize;
  280. OMX_VERSIONTYPE nVersion;
  281. OMX_U32 nPortIndex;
  282. OMX_U32 nWidth;
  283. OMX_U32 nHeight;
  284. } OMX_FRAMESIZETYPE;
  285. /**
  286. * Rotation configuration
  287. *
  288. * STRUCT MEMBERS:
  289. * nSize : Size of the structure in bytes
  290. * nVersion : OMX specification version information
  291. * nPortIndex : Port that this structure applies to
  292. * nRotation : +/- integer rotation value
  293. */
  294. typedef struct OMX_CONFIG_ROTATIONTYPE {
  295. OMX_U32 nSize;
  296. OMX_VERSIONTYPE nVersion;
  297. OMX_U32 nPortIndex;
  298. OMX_S32 nRotation;
  299. } OMX_CONFIG_ROTATIONTYPE;
  300. /**
  301. * Possible mirroring directions for pre/post processing
  302. *
  303. * ENUMS:
  304. * None : No mirroring
  305. * Vertical : Vertical mirroring, flip on X axis
  306. * Horizontal : Horizontal mirroring, flip on Y axis
  307. * Both : Both vertical and horizontal mirroring
  308. */
  309. typedef enum OMX_MIRRORTYPE {
  310. OMX_MirrorNone = 0,
  311. OMX_MirrorVertical,
  312. OMX_MirrorHorizontal,
  313. OMX_MirrorBoth,
  314. OMX_MirrorKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  315. OMX_MirrorVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  316. OMX_MirrorMax = 0x7FFFFFFF
  317. } OMX_MIRRORTYPE;
  318. /**
  319. * Mirroring configuration
  320. *
  321. * STRUCT MEMBERS:
  322. * nSize : Size of the structure in bytes
  323. * nVersion : OMX specification version information
  324. * nPortIndex : Port that this structure applies to
  325. * eMirror : Mirror type enumeration
  326. */
  327. typedef struct OMX_CONFIG_MIRRORTYPE {
  328. OMX_U32 nSize;
  329. OMX_VERSIONTYPE nVersion;
  330. OMX_U32 nPortIndex;
  331. OMX_MIRRORTYPE eMirror;
  332. } OMX_CONFIG_MIRRORTYPE;
  333. /**
  334. * Position information only
  335. *
  336. * STRUCT MEMBERS:
  337. * nSize : Size of the structure in bytes
  338. * nVersion : OMX specification version information
  339. * nPortIndex : Port that this structure applies to
  340. * nX : X coordinate for the point
  341. * nY : Y coordinate for the point
  342. */
  343. typedef struct OMX_CONFIG_POINTTYPE {
  344. OMX_U32 nSize;
  345. OMX_VERSIONTYPE nVersion;
  346. OMX_U32 nPortIndex;
  347. OMX_S32 nX;
  348. OMX_S32 nY;
  349. } OMX_CONFIG_POINTTYPE;
  350. /**
  351. * Frame size plus position
  352. *
  353. * STRUCT MEMBERS:
  354. * nSize : Size of the structure in bytes
  355. * nVersion : OMX specification version information
  356. * nPortIndex : Port that this structure applies to
  357. * nLeft : X Coordinate of the top left corner of the rectangle
  358. * nTop : Y Coordinate of the top left corner of the rectangle
  359. * nWidth : Width of the rectangle
  360. * nHeight : Height of the rectangle
  361. */
  362. typedef struct OMX_CONFIG_RECTTYPE {
  363. OMX_U32 nSize;
  364. OMX_VERSIONTYPE nVersion;
  365. OMX_U32 nPortIndex;
  366. OMX_S32 nLeft;
  367. OMX_S32 nTop;
  368. OMX_U32 nWidth;
  369. OMX_U32 nHeight;
  370. } OMX_CONFIG_RECTTYPE;
  371. /**
  372. * Deblocking state; it is required to be set up before starting the codec
  373. *
  374. * STRUCT MEMBERS:
  375. * nSize : Size of the structure in bytes
  376. * nVersion : OMX specification version information
  377. * nPortIndex : Port that this structure applies to
  378. * bDeblocking : Enable/disable deblocking mode
  379. */
  380. typedef struct OMX_PARAM_DEBLOCKINGTYPE {
  381. OMX_U32 nSize;
  382. OMX_VERSIONTYPE nVersion;
  383. OMX_U32 nPortIndex;
  384. OMX_BOOL bDeblocking;
  385. } OMX_PARAM_DEBLOCKINGTYPE;
  386. /**
  387. * Stabilization state
  388. *
  389. * STRUCT MEMBERS:
  390. * nSize : Size of the structure in bytes
  391. * nVersion : OMX specification version information
  392. * nPortIndex : Port that this structure applies to
  393. * bStab : Enable/disable frame stabilization state
  394. */
  395. typedef struct OMX_CONFIG_FRAMESTABTYPE {
  396. OMX_U32 nSize;
  397. OMX_VERSIONTYPE nVersion;
  398. OMX_U32 nPortIndex;
  399. OMX_BOOL bStab;
  400. } OMX_CONFIG_FRAMESTABTYPE;
  401. /**
  402. * White Balance control type
  403. *
  404. * STRUCT MEMBERS:
  405. * SunLight : Referenced in JSR-234
  406. * Flash : Optimal for device's integrated flash
  407. */
  408. typedef enum OMX_WHITEBALCONTROLTYPE {
  409. OMX_WhiteBalControlOff = 0,
  410. OMX_WhiteBalControlAuto,
  411. OMX_WhiteBalControlSunLight,
  412. OMX_WhiteBalControlCloudy,
  413. OMX_WhiteBalControlShade,
  414. OMX_WhiteBalControlTungsten,
  415. OMX_WhiteBalControlFluorescent,
  416. OMX_WhiteBalControlIncandescent,
  417. OMX_WhiteBalControlFlash,
  418. OMX_WhiteBalControlHorizon,
  419. OMX_WhiteBalControlKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  420. OMX_WhiteBalControlVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  421. OMX_WhiteBalControlMax = 0x7FFFFFFF
  422. } OMX_WHITEBALCONTROLTYPE;
  423. /**
  424. * White Balance control configuration
  425. *
  426. * STRUCT MEMBERS:
  427. * nSize : Size of the structure in bytes
  428. * nVersion : OMX specification version information
  429. * nPortIndex : Port that this structure applies to
  430. * eWhiteBalControl : White balance enumeration
  431. */
  432. typedef struct OMX_CONFIG_WHITEBALCONTROLTYPE {
  433. OMX_U32 nSize;
  434. OMX_VERSIONTYPE nVersion;
  435. OMX_U32 nPortIndex;
  436. OMX_WHITEBALCONTROLTYPE eWhiteBalControl;
  437. } OMX_CONFIG_WHITEBALCONTROLTYPE;
  438. /**
  439. * Exposure control type
  440. */
  441. typedef enum OMX_EXPOSURECONTROLTYPE {
  442. OMX_ExposureControlOff = 0,
  443. OMX_ExposureControlAuto,
  444. OMX_ExposureControlNight,
  445. OMX_ExposureControlBackLight,
  446. OMX_ExposureControlSpotLight,
  447. OMX_ExposureControlSports,
  448. OMX_ExposureControlSnow,
  449. OMX_ExposureControlBeach,
  450. OMX_ExposureControlLargeAperture,
  451. OMX_ExposureControlSmallApperture,
  452. OMX_ExposureControlKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  453. OMX_ExposureControlVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  454. OMX_ExposureControlMax = 0x7FFFFFFF
  455. } OMX_EXPOSURECONTROLTYPE;
  456. /**
  457. * White Balance control configuration
  458. *
  459. * STRUCT MEMBERS:
  460. * nSize : Size of the structure in bytes
  461. * nVersion : OMX specification version information
  462. * nPortIndex : Port that this structure applies to
  463. * eExposureControl : Exposure control enumeration
  464. */
  465. typedef struct OMX_CONFIG_EXPOSURECONTROLTYPE {
  466. OMX_U32 nSize;
  467. OMX_VERSIONTYPE nVersion;
  468. OMX_U32 nPortIndex;
  469. OMX_EXPOSURECONTROLTYPE eExposureControl;
  470. } OMX_CONFIG_EXPOSURECONTROLTYPE;
  471. /**
  472. * Defines sensor supported mode.
  473. *
  474. * STRUCT MEMBERS:
  475. * nSize : Size of the structure in bytes
  476. * nVersion : OMX specification version information
  477. * nPortIndex : Port that this structure applies to
  478. * nFrameRate : Single shot mode is indicated by a 0
  479. * bOneShot : Enable for single shot, disable for streaming
  480. * sFrameSize : Framesize
  481. */
  482. typedef struct OMX_PARAM_SENSORMODETYPE {
  483. OMX_U32 nSize;
  484. OMX_VERSIONTYPE nVersion;
  485. OMX_U32 nPortIndex;
  486. OMX_U32 nFrameRate;
  487. OMX_BOOL bOneShot;
  488. OMX_FRAMESIZETYPE sFrameSize;
  489. } OMX_PARAM_SENSORMODETYPE;
  490. /**
  491. * Defines contrast level
  492. *
  493. * STRUCT MEMBERS:
  494. * nSize : Size of the structure in bytes
  495. * nVersion : OMX specification version information
  496. * nPortIndex : Port that this structure applies to
  497. * nContrast : Values allowed for contrast -100 to 100, zero means no change
  498. */
  499. typedef struct OMX_CONFIG_CONTRASTTYPE {
  500. OMX_U32 nSize;
  501. OMX_VERSIONTYPE nVersion;
  502. OMX_U32 nPortIndex;
  503. OMX_S32 nContrast;
  504. } OMX_CONFIG_CONTRASTTYPE;
  505. /**
  506. * Defines brightness level
  507. *
  508. * STRUCT MEMBERS:
  509. * nSize : Size of the structure in bytes
  510. * nVersion : OMX specification version information
  511. * nPortIndex : Port that this structure applies to
  512. * nBrightness : 0-100%
  513. */
  514. typedef struct OMX_CONFIG_BRIGHTNESSTYPE {
  515. OMX_U32 nSize;
  516. OMX_VERSIONTYPE nVersion;
  517. OMX_U32 nPortIndex;
  518. OMX_U32 nBrightness;
  519. } OMX_CONFIG_BRIGHTNESSTYPE;
  520. /**
  521. * Defines backlight level configuration for a video sink, e.g. LCD panel
  522. *
  523. * STRUCT MEMBERS:
  524. * nSize : Size of the structure in bytes
  525. * nVersion : OMX specification version information
  526. * nPortIndex : Port that this structure applies to
  527. * nBacklight : Values allowed for backlight 0-100%
  528. * nTimeout : Number of milliseconds before backlight automatically turns
  529. * off. A value of 0x0 disables backight timeout
  530. */
  531. typedef struct OMX_CONFIG_BACKLIGHTTYPE {
  532. OMX_U32 nSize;
  533. OMX_VERSIONTYPE nVersion;
  534. OMX_U32 nPortIndex;
  535. OMX_U32 nBacklight;
  536. OMX_U32 nTimeout;
  537. } OMX_CONFIG_BACKLIGHTTYPE;
  538. /**
  539. * Defines setting for Gamma
  540. *
  541. * STRUCT MEMBERS:
  542. * nSize : Size of the structure in bytes
  543. * nVersion : OMX specification version information
  544. * nPortIndex : Port that this structure applies to
  545. * nGamma : Values allowed for gamma -100 to 100, zero means no change
  546. */
  547. typedef struct OMX_CONFIG_GAMMATYPE {
  548. OMX_U32 nSize;
  549. OMX_VERSIONTYPE nVersion;
  550. OMX_U32 nPortIndex;
  551. OMX_S32 nGamma;
  552. } OMX_CONFIG_GAMMATYPE;
  553. /**
  554. * Define for setting saturation
  555. *
  556. * STRUCT MEMBERS:
  557. * nSize : Size of the structure in bytes
  558. * nVersion : OMX specification version information
  559. * nPortIndex : Port that this structure applies to
  560. * nSaturation : Values allowed for saturation -100 to 100, zero means
  561. * no change
  562. */
  563. typedef struct OMX_CONFIG_SATURATIONTYPE {
  564. OMX_U32 nSize;
  565. OMX_VERSIONTYPE nVersion;
  566. OMX_U32 nPortIndex;
  567. OMX_S32 nSaturation;
  568. } OMX_CONFIG_SATURATIONTYPE;
  569. /**
  570. * Define for setting Lightness
  571. *
  572. * STRUCT MEMBERS:
  573. * nSize : Size of the structure in bytes
  574. * nVersion : OMX specification version information
  575. * nPortIndex : Port that this structure applies to
  576. * nLightness : Values allowed for lightness -100 to 100, zero means no
  577. * change
  578. */
  579. typedef struct OMX_CONFIG_LIGHTNESSTYPE {
  580. OMX_U32 nSize;
  581. OMX_VERSIONTYPE nVersion;
  582. OMX_U32 nPortIndex;
  583. OMX_S32 nLightness;
  584. } OMX_CONFIG_LIGHTNESSTYPE;
  585. /**
  586. * Plane blend configuration
  587. *
  588. * STRUCT MEMBERS:
  589. * nSize : Size of the structure in bytes
  590. * nVersion : OMX specification version information
  591. * nPortIndex : Index of input port associated with the plane.
  592. * nDepth : Depth of the plane in relation to the screen. Higher
  593. * numbered depths are "behind" lower number depths.
  594. * This number defaults to the Port Index number.
  595. * nAlpha : Transparency blending component for the entire plane.
  596. * See blending modes for more detail.
  597. */
  598. typedef struct OMX_CONFIG_PLANEBLENDTYPE {
  599. OMX_U32 nSize;
  600. OMX_VERSIONTYPE nVersion;
  601. OMX_U32 nPortIndex;
  602. OMX_U32 nDepth;
  603. OMX_U32 nAlpha;
  604. } OMX_CONFIG_PLANEBLENDTYPE;
  605. /**
  606. * Define interlace type
  607. *
  608. * STRUCT MEMBERS:
  609. * nSize : Size of the structure in bytes
  610. * nVersion : OMX specification version information
  611. * nPortIndex : Port that this structure applies to
  612. * bEnable : Enable control variable for this functionality
  613. * (see below)
  614. * nInterleavePortIndex : Index of input or output port associated with
  615. * the interleaved plane.
  616. * pPlanarPortIndexes[4] : Index of input or output planar ports.
  617. */
  618. typedef struct OMX_PARAM_INTERLEAVETYPE {
  619. OMX_U32 nSize;
  620. OMX_VERSIONTYPE nVersion;
  621. OMX_U32 nPortIndex;
  622. OMX_BOOL bEnable;
  623. OMX_U32 nInterleavePortIndex;
  624. } OMX_PARAM_INTERLEAVETYPE;
  625. /**
  626. * Defines the picture effect used for an input picture
  627. */
  628. typedef enum OMX_TRANSITIONEFFECTTYPE {
  629. OMX_EffectNone,
  630. OMX_EffectFadeFromBlack,
  631. OMX_EffectFadeToBlack,
  632. OMX_EffectUnspecifiedThroughConstantColor,
  633. OMX_EffectDissolve,
  634. OMX_EffectWipe,
  635. OMX_EffectUnspecifiedMixOfTwoScenes,
  636. OMX_EffectKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  637. OMX_EffectVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  638. OMX_EffectMax = 0x7FFFFFFF
  639. } OMX_TRANSITIONEFFECTTYPE;
  640. /**
  641. * Structure used to configure current transition effect
  642. *
  643. * STRUCT MEMBERS:
  644. * nSize : Size of the structure in bytes
  645. * nVersion : OMX specification version information
  646. * nPortIndex : Port that this structure applies to
  647. * eEffect : Effect to enable
  648. */
  649. typedef struct OMX_CONFIG_TRANSITIONEFFECTTYPE {
  650. OMX_U32 nSize;
  651. OMX_VERSIONTYPE nVersion;
  652. OMX_U32 nPortIndex;
  653. OMX_TRANSITIONEFFECTTYPE eEffect;
  654. } OMX_CONFIG_TRANSITIONEFFECTTYPE;
  655. /**
  656. * Defines possible data unit types for encoded video data. The data unit
  657. * types are used both for encoded video input for playback as well as
  658. * encoded video output from recording.
  659. */
  660. typedef enum OMX_DATAUNITTYPE {
  661. OMX_DataUnitCodedPicture,
  662. OMX_DataUnitVideoSegment,
  663. OMX_DataUnitSeveralSegments,
  664. OMX_DataUnitArbitraryStreamSection,
  665. OMX_DataUnitKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  666. OMX_DataUnitVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  667. OMX_DataUnitMax = 0x7FFFFFFF
  668. } OMX_DATAUNITTYPE;
  669. /**
  670. * Defines possible encapsulation types for coded video data unit. The
  671. * encapsulation information is used both for encoded video input for
  672. * playback as well as encoded video output from recording.
  673. */
  674. typedef enum OMX_DATAUNITENCAPSULATIONTYPE {
  675. OMX_DataEncapsulationElementaryStream,
  676. OMX_DataEncapsulationGenericPayload,
  677. OMX_DataEncapsulationRtpPayload,
  678. OMX_DataEncapsulationKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  679. OMX_DataEncapsulationVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  680. OMX_DataEncapsulationMax = 0x7FFFFFFF
  681. } OMX_DATAUNITENCAPSULATIONTYPE;
  682. /**
  683. * Structure used to configure the type of being decoded/encoded
  684. */
  685. typedef struct OMX_PARAM_DATAUNITTYPE {
  686. OMX_U32 nSize; /**< Size of the structure in bytes */
  687. OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
  688. OMX_U32 nPortIndex; /**< Port that this structure applies to */
  689. OMX_DATAUNITTYPE eUnitType;
  690. OMX_DATAUNITENCAPSULATIONTYPE eEncapsulationType;
  691. } OMX_PARAM_DATAUNITTYPE;
  692. /**
  693. * Defines dither types
  694. */
  695. typedef enum OMX_DITHERTYPE {
  696. OMX_DitherNone,
  697. OMX_DitherOrdered,
  698. OMX_DitherErrorDiffusion,
  699. OMX_DitherOther,
  700. OMX_DitherKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  701. OMX_DitherVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  702. OMX_DitherMax = 0x7FFFFFFF
  703. } OMX_DITHERTYPE;
  704. /**
  705. * Structure used to configure current type of dithering
  706. */
  707. typedef struct OMX_CONFIG_DITHERTYPE {
  708. OMX_U32 nSize; /**< Size of the structure in bytes */
  709. OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
  710. OMX_U32 nPortIndex; /**< Port that this structure applies to */
  711. OMX_DITHERTYPE eDither; /**< Type of dithering to use */
  712. } OMX_CONFIG_DITHERTYPE;
  713. typedef struct OMX_CONFIG_CAPTUREMODETYPE {
  714. OMX_U32 nSize;
  715. OMX_VERSIONTYPE nVersion;
  716. OMX_U32 nPortIndex; /**< Port that this structure applies to */
  717. OMX_BOOL bContinuous; /**< If true then ignore frame rate and emit capture
  718. * data as fast as possible (otherwise obey port's frame rate). */
  719. OMX_BOOL bFrameLimited; /**< If true then terminate capture after the port emits the
  720. * specified number of frames (otherwise the port does not
  721. * terminate the capture until instructed to do so by the client).
  722. * Even if set, the client may manually terminate the capture prior
  723. * to reaching the limit. */
  724. OMX_U32 nFrameLimit; /**< Limit on number of frames emitted during a capture (only
  725. * valid if bFrameLimited is set). */
  726. } OMX_CONFIG_CAPTUREMODETYPE;
  727. typedef enum OMX_METERINGTYPE {
  728. OMX_MeteringModeAverage, /**< Center-weighted average metering. */
  729. OMX_MeteringModeSpot, /**< Spot (partial) metering. */
  730. OMX_MeteringModeMatrix, /**< Matrix or evaluative metering. */
  731. OMX_MeteringKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  732. OMX_MeteringVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  733. OMX_EVModeMax = 0x7fffffff
  734. } OMX_METERINGTYPE;
  735. typedef struct OMX_CONFIG_EXPOSUREVALUETYPE {
  736. OMX_U32 nSize;
  737. OMX_VERSIONTYPE nVersion;
  738. OMX_U32 nPortIndex;
  739. OMX_METERINGTYPE eMetering;
  740. OMX_S32 xEVCompensation; /**< Fixed point value stored as Q16 */
  741. OMX_U32 nApertureFNumber; /**< e.g. nApertureFNumber = 2 implies "f/2" - Q16 format */
  742. OMX_BOOL bAutoAperture; /**< Whether aperture number is defined automatically */
  743. OMX_U32 nShutterSpeedMsec; /**< Shutterspeed in milliseconds */
  744. OMX_BOOL bAutoShutterSpeed; /**< Whether shutter speed is defined automatically */
  745. OMX_U32 nSensitivity; /**< e.g. nSensitivity = 100 implies "ISO 100" */
  746. OMX_BOOL bAutoSensitivity; /**< Whether sensitivity is defined automatically */
  747. } OMX_CONFIG_EXPOSUREVALUETYPE;
  748. /**
  749. * Focus region configuration
  750. *
  751. * STRUCT MEMBERS:
  752. * nSize : Size of the structure in bytes
  753. * nVersion : OMX specification version information
  754. * nPortIndex : Port that this structure applies to
  755. * bCenter : Use center region as focus region of interest
  756. * bLeft : Use left region as focus region of interest
  757. * bRight : Use right region as focus region of interest
  758. * bTop : Use top region as focus region of interest
  759. * bBottom : Use bottom region as focus region of interest
  760. * bTopLeft : Use top left region as focus region of interest
  761. * bTopRight : Use top right region as focus region of interest
  762. * bBottomLeft : Use bottom left region as focus region of interest
  763. * bBottomRight : Use bottom right region as focus region of interest
  764. */
  765. typedef struct OMX_CONFIG_FOCUSREGIONTYPE {
  766. OMX_U32 nSize;
  767. OMX_VERSIONTYPE nVersion;
  768. OMX_U32 nPortIndex;
  769. OMX_BOOL bCenter;
  770. OMX_BOOL bLeft;
  771. OMX_BOOL bRight;
  772. OMX_BOOL bTop;
  773. OMX_BOOL bBottom;
  774. OMX_BOOL bTopLeft;
  775. OMX_BOOL bTopRight;
  776. OMX_BOOL bBottomLeft;
  777. OMX_BOOL bBottomRight;
  778. } OMX_CONFIG_FOCUSREGIONTYPE;
  779. /**
  780. * Focus Status type
  781. */
  782. typedef enum OMX_FOCUSSTATUSTYPE {
  783. OMX_FocusStatusOff = 0,
  784. OMX_FocusStatusRequest,
  785. OMX_FocusStatusReached,
  786. OMX_FocusStatusUnableToReach,
  787. OMX_FocusStatusLost,
  788. OMX_FocusStatusKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  789. OMX_FocusStatusVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  790. OMX_FocusStatusMax = 0x7FFFFFFF
  791. } OMX_FOCUSSTATUSTYPE;
  792. /**
  793. * Focus status configuration
  794. *
  795. * STRUCT MEMBERS:
  796. * nSize : Size of the structure in bytes
  797. * nVersion : OMX specification version information
  798. * nPortIndex : Port that this structure applies to
  799. * eFocusStatus : Specifies the focus status
  800. * bCenterStatus : Use center region as focus region of interest
  801. * bLeftStatus : Use left region as focus region of interest
  802. * bRightStatus : Use right region as focus region of interest
  803. * bTopStatus : Use top region as focus region of interest
  804. * bBottomStatus : Use bottom region as focus region of interest
  805. * bTopLeftStatus : Use top left region as focus region of interest
  806. * bTopRightStatus : Use top right region as focus region of interest
  807. * bBottomLeftStatus : Use bottom left region as focus region of interest
  808. * bBottomRightStatus : Use bottom right region as focus region of interest
  809. */
  810. typedef struct OMX_PARAM_FOCUSSTATUSTYPE {
  811. OMX_U32 nSize;
  812. OMX_VERSIONTYPE nVersion;
  813. OMX_U32 nPortIndex;
  814. OMX_FOCUSSTATUSTYPE eFocusStatus;
  815. OMX_BOOL bCenterStatus;
  816. OMX_BOOL bLeftStatus;
  817. OMX_BOOL bRightStatus;
  818. OMX_BOOL bTopStatus;
  819. OMX_BOOL bBottomStatus;
  820. OMX_BOOL bTopLeftStatus;
  821. OMX_BOOL bTopRightStatus;
  822. OMX_BOOL bBottomLeftStatus;
  823. OMX_BOOL bBottomRightStatus;
  824. } OMX_PARAM_FOCUSSTATUSTYPE;
  825. /** @} */
  826. #ifdef __cplusplus
  827. }
  828. #endif /* __cplusplus */
  829. #endif
  830. /* File EOF */