OMX_Video.h 43 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061
  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_Video.h - OpenMax IL version 1.1.2
  25. * The structures is needed by Video components to exchange parameters
  26. * and configuration data with OMX components.
  27. */
  28. #ifndef OMX_Video_h
  29. #define OMX_Video_h
  30. /** @defgroup video OpenMAX IL Video Domain
  31. * @ingroup iv
  32. * Structures for OpenMAX IL Video domain
  33. * @{
  34. */
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif /* __cplusplus */
  38. /**
  39. * Each OMX header must include all required header files to allow the
  40. * header to compile without errors. The includes below are required
  41. * for this header file to compile successfully
  42. */
  43. #include <OMX_IVCommon.h>
  44. /**
  45. * Enumeration used to define the possible video compression codings.
  46. * NOTE: This essentially refers to file extensions. If the coding is
  47. * being used to specify the ENCODE type, then additional work
  48. * must be done to configure the exact flavor of the compression
  49. * to be used. For decode cases where the user application can
  50. * not differentiate between MPEG-4 and H.264 bit streams, it is
  51. * up to the codec to handle this.
  52. */
  53. typedef enum OMX_VIDEO_CODINGTYPE {
  54. OMX_VIDEO_CodingUnused, /**< Value when coding is N/A */
  55. OMX_VIDEO_CodingAutoDetect, /**< Autodetection of coding type */
  56. OMX_VIDEO_CodingMPEG2, /**< AKA: H.262 */
  57. OMX_VIDEO_CodingH263, /**< H.263 */
  58. OMX_VIDEO_CodingMPEG4, /**< MPEG-4 */
  59. OMX_VIDEO_CodingWMV, /**< all versions of Windows Media Video */
  60. OMX_VIDEO_CodingRV, /**< all versions of Real Video */
  61. OMX_VIDEO_CodingAVC, /**< H.264/AVC */
  62. OMX_VIDEO_CodingMJPEG, /**< Motion JPEG */
  63. OMX_VIDEO_CodingKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  64. OMX_VIDEO_CodingVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  65. OMX_VIDEO_CodingMax = 0x7FFFFFFF
  66. } OMX_VIDEO_CODINGTYPE;
  67. /**
  68. * Data structure used to define a video path. The number of Video paths for
  69. * input and output will vary by type of the Video component.
  70. *
  71. * Input (aka Source) : zero Inputs, one Output,
  72. * Splitter : one Input, 2 or more Outputs,
  73. * Processing Element : one Input, one output,
  74. * Mixer : 2 or more inputs, one output,
  75. * Output (aka Sink) : one Input, zero outputs.
  76. *
  77. * The PortDefinition structure is used to define all of the parameters
  78. * necessary for the compliant component to setup an input or an output video
  79. * path. If additional vendor specific data is required, it should be
  80. * transmitted to the component using the CustomCommand function. Compliant
  81. * components will prepopulate this structure with optimal values during the
  82. * GetDefaultInitParams command.
  83. *
  84. * STRUCT MEMBERS:
  85. * cMIMEType : MIME type of data for the port
  86. * pNativeRender : Platform specific reference for a display if a
  87. * sync, otherwise this field is 0
  88. * nFrameWidth : Width of frame to be used on channel if
  89. * uncompressed format is used. Use 0 for unknown,
  90. * don't care or variable
  91. * nFrameHeight : Height of frame to be used on channel if
  92. * uncompressed format is used. Use 0 for unknown,
  93. * don't care or variable
  94. * nStride : Number of bytes per span of an image
  95. * (i.e. indicates the number of bytes to get
  96. * from span N to span N+1, where negative stride
  97. * indicates the image is bottom up
  98. * nSliceHeight : Height used when encoding in slices
  99. * nBitrate : Bit rate of frame to be used on channel if
  100. * compressed format is used. Use 0 for unknown,
  101. * don't care or variable
  102. * xFramerate : Frame rate to be used on channel if uncompressed
  103. * format is used. Use 0 for unknown, don't care or
  104. * variable. Units are Q16 frames per second.
  105. * bFlagErrorConcealment : Turns on error concealment if it is supported by
  106. * the OMX component
  107. * eCompressionFormat : Compression format used in this instance of the
  108. * component. When OMX_VIDEO_CodingUnused is
  109. * specified, eColorFormat is used
  110. * eColorFormat : Decompressed format used by this component
  111. * pNativeWindow : Platform specific reference for a window object if a
  112. * display sink , otherwise this field is 0x0.
  113. */
  114. typedef struct OMX_VIDEO_PORTDEFINITIONTYPE {
  115. OMX_STRING cMIMEType;
  116. OMX_NATIVE_DEVICETYPE pNativeRender;
  117. OMX_U32 nFrameWidth;
  118. OMX_U32 nFrameHeight;
  119. OMX_S32 nStride;
  120. OMX_U32 nSliceHeight;
  121. OMX_U32 nBitrate;
  122. OMX_U32 xFramerate;
  123. OMX_BOOL bFlagErrorConcealment;
  124. OMX_VIDEO_CODINGTYPE eCompressionFormat;
  125. OMX_COLOR_FORMATTYPE eColorFormat;
  126. OMX_NATIVE_WINDOWTYPE pNativeWindow;
  127. } OMX_VIDEO_PORTDEFINITIONTYPE;
  128. /**
  129. * Port format parameter. This structure is used to enumerate the various
  130. * data input/output format supported by the port.
  131. *
  132. * STRUCT MEMBERS:
  133. * nSize : Size of the structure in bytes
  134. * nVersion : OMX specification version information
  135. * nPortIndex : Indicates which port to set
  136. * nIndex : Indicates the enumeration index for the format from
  137. * 0x0 to N-1
  138. * eCompressionFormat : Compression format used in this instance of the
  139. * component. When OMX_VIDEO_CodingUnused is specified,
  140. * eColorFormat is used
  141. * eColorFormat : Decompressed format used by this component
  142. * xFrameRate : Indicates the video frame rate in Q16 format
  143. */
  144. typedef struct OMX_VIDEO_PARAM_PORTFORMATTYPE {
  145. OMX_U32 nSize;
  146. OMX_VERSIONTYPE nVersion;
  147. OMX_U32 nPortIndex;
  148. OMX_U32 nIndex;
  149. OMX_VIDEO_CODINGTYPE eCompressionFormat;
  150. OMX_COLOR_FORMATTYPE eColorFormat;
  151. OMX_U32 xFramerate;
  152. } OMX_VIDEO_PARAM_PORTFORMATTYPE;
  153. /**
  154. * This is a structure for configuring video compression quantization
  155. * parameter values. Codecs may support different QP values for different
  156. * frame types.
  157. *
  158. * STRUCT MEMBERS:
  159. * nSize : Size of the structure in bytes
  160. * nVersion : OMX specification version info
  161. * nPortIndex : Port that this structure applies to
  162. * nQpI : QP value to use for index frames
  163. * nQpP : QP value to use for P frames
  164. * nQpB : QP values to use for bidirectional frames
  165. */
  166. typedef struct OMX_VIDEO_PARAM_QUANTIZATIONTYPE {
  167. OMX_U32 nSize;
  168. OMX_VERSIONTYPE nVersion;
  169. OMX_U32 nPortIndex;
  170. OMX_U32 nQpI;
  171. OMX_U32 nQpP;
  172. OMX_U32 nQpB;
  173. } OMX_VIDEO_PARAM_QUANTIZATIONTYPE;
  174. /**
  175. * Structure for configuration of video fast update parameters.
  176. *
  177. * STRUCT MEMBERS:
  178. * nSize : Size of the structure in bytes
  179. * nVersion : OMX specification version info
  180. * nPortIndex : Port that this structure applies to
  181. * bEnableVFU : Enable/Disable video fast update
  182. * nFirstGOB : Specifies the number of the first macroblock row
  183. * nFirstMB : specifies the first MB relative to the specified first GOB
  184. * nNumMBs : Specifies the number of MBs to be refreshed from nFirstGOB
  185. * and nFirstMB
  186. */
  187. typedef struct OMX_VIDEO_PARAM_VIDEOFASTUPDATETYPE {
  188. OMX_U32 nSize;
  189. OMX_VERSIONTYPE nVersion;
  190. OMX_U32 nPortIndex;
  191. OMX_BOOL bEnableVFU;
  192. OMX_U32 nFirstGOB;
  193. OMX_U32 nFirstMB;
  194. OMX_U32 nNumMBs;
  195. } OMX_VIDEO_PARAM_VIDEOFASTUPDATETYPE;
  196. /**
  197. * Enumeration of possible bitrate control types
  198. */
  199. typedef enum OMX_VIDEO_CONTROLRATETYPE {
  200. OMX_Video_ControlRateDisable,
  201. OMX_Video_ControlRateVariable,
  202. OMX_Video_ControlRateConstant,
  203. OMX_Video_ControlRateVariableSkipFrames,
  204. OMX_Video_ControlRateConstantSkipFrames,
  205. OMX_Video_ControlRateKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  206. OMX_Video_ControlRateVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  207. OMX_Video_ControlRateMax = 0x7FFFFFFF
  208. } OMX_VIDEO_CONTROLRATETYPE;
  209. /**
  210. * Structure for configuring bitrate mode of a codec.
  211. *
  212. * STRUCT MEMBERS:
  213. * nSize : Size of the struct in bytes
  214. * nVersion : OMX spec version info
  215. * nPortIndex : Port that this struct applies to
  216. * eControlRate : Control rate type enum
  217. * nTargetBitrate : Target bitrate to encode with
  218. */
  219. typedef struct OMX_VIDEO_PARAM_BITRATETYPE {
  220. OMX_U32 nSize;
  221. OMX_VERSIONTYPE nVersion;
  222. OMX_U32 nPortIndex;
  223. OMX_VIDEO_CONTROLRATETYPE eControlRate;
  224. OMX_U32 nTargetBitrate;
  225. } OMX_VIDEO_PARAM_BITRATETYPE;
  226. /**
  227. * Enumeration of possible motion vector (MV) types
  228. */
  229. typedef enum OMX_VIDEO_MOTIONVECTORTYPE {
  230. OMX_Video_MotionVectorPixel,
  231. OMX_Video_MotionVectorHalfPel,
  232. OMX_Video_MotionVectorQuarterPel,
  233. OMX_Video_MotionVectorEighthPel,
  234. OMX_Video_MotionVectorKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  235. OMX_Video_MotionVectorVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  236. OMX_Video_MotionVectorMax = 0x7FFFFFFF
  237. } OMX_VIDEO_MOTIONVECTORTYPE;
  238. /**
  239. * Structure for configuring the number of motion vectors used as well
  240. * as their accuracy.
  241. *
  242. * STRUCT MEMBERS:
  243. * nSize : Size of the struct in bytes
  244. * nVersion : OMX spec version info
  245. * nPortIndex : port that this structure applies to
  246. * eAccuracy : Enumerated MV accuracy
  247. * bUnrestrictedMVs : Allow unrestricted MVs
  248. * bFourMV : Allow use of 4 MVs
  249. * sXSearchRange : Search range in horizontal direction for MVs
  250. * sYSearchRange : Search range in vertical direction for MVs
  251. */
  252. typedef struct OMX_VIDEO_PARAM_MOTIONVECTORTYPE {
  253. OMX_U32 nSize;
  254. OMX_VERSIONTYPE nVersion;
  255. OMX_U32 nPortIndex;
  256. OMX_VIDEO_MOTIONVECTORTYPE eAccuracy;
  257. OMX_BOOL bUnrestrictedMVs;
  258. OMX_BOOL bFourMV;
  259. OMX_S32 sXSearchRange;
  260. OMX_S32 sYSearchRange;
  261. } OMX_VIDEO_PARAM_MOTIONVECTORTYPE;
  262. /**
  263. * Enumeration of possible methods to use for Intra Refresh
  264. */
  265. typedef enum OMX_VIDEO_INTRAREFRESHTYPE {
  266. OMX_VIDEO_IntraRefreshCyclic,
  267. OMX_VIDEO_IntraRefreshAdaptive,
  268. OMX_VIDEO_IntraRefreshBoth,
  269. OMX_VIDEO_IntraRefreshKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  270. OMX_VIDEO_IntraRefreshVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  271. OMX_VIDEO_IntraRefreshMax = 0x7FFFFFFF
  272. } OMX_VIDEO_INTRAREFRESHTYPE;
  273. /**
  274. * Structure for configuring intra refresh mode
  275. *
  276. * STRUCT MEMBERS:
  277. * nSize : Size of the structure in bytes
  278. * nVersion : OMX specification version information
  279. * nPortIndex : Port that this structure applies to
  280. * eRefreshMode : Cyclic, Adaptive, or Both
  281. * nAirMBs : Number of intra macroblocks to refresh in a frame when
  282. * AIR is enabled
  283. * nAirRef : Number of times a motion marked macroblock has to be
  284. * intra coded
  285. * nCirMBs : Number of consecutive macroblocks to be coded as "intra"
  286. * when CIR is enabled
  287. */
  288. typedef struct OMX_VIDEO_PARAM_INTRAREFRESHTYPE {
  289. OMX_U32 nSize;
  290. OMX_VERSIONTYPE nVersion;
  291. OMX_U32 nPortIndex;
  292. OMX_VIDEO_INTRAREFRESHTYPE eRefreshMode;
  293. OMX_U32 nAirMBs;
  294. OMX_U32 nAirRef;
  295. OMX_U32 nCirMBs;
  296. } OMX_VIDEO_PARAM_INTRAREFRESHTYPE;
  297. /**
  298. * Structure for enabling various error correction methods for video
  299. * compression.
  300. *
  301. * STRUCT MEMBERS:
  302. * nSize : Size of the structure in bytes
  303. * nVersion : OMX specification version information
  304. * nPortIndex : Port that this structure applies to
  305. * bEnableHEC : Enable/disable header extension codes (HEC)
  306. * bEnableResync : Enable/disable resynchronization markers
  307. * nResynchMarkerSpacing : Resynch markers interval (in bits) to be
  308. * applied in the stream
  309. * bEnableDataPartitioning : Enable/disable data partitioning
  310. * bEnableRVLC : Enable/disable reversible variable length
  311. * coding
  312. */
  313. typedef struct OMX_VIDEO_PARAM_ERRORCORRECTIONTYPE {
  314. OMX_U32 nSize;
  315. OMX_VERSIONTYPE nVersion;
  316. OMX_U32 nPortIndex;
  317. OMX_BOOL bEnableHEC;
  318. OMX_BOOL bEnableResync;
  319. OMX_U32 nResynchMarkerSpacing;
  320. OMX_BOOL bEnableDataPartitioning;
  321. OMX_BOOL bEnableRVLC;
  322. } OMX_VIDEO_PARAM_ERRORCORRECTIONTYPE;
  323. /**
  324. * Configuration of variable block-size motion compensation (VBSMC)
  325. *
  326. * STRUCT MEMBERS:
  327. * nSize : Size of the structure in bytes
  328. * nVersion : OMX specification version information
  329. * nPortIndex : Port that this structure applies to
  330. * b16x16 : Enable inter block search 16x16
  331. * b16x8 : Enable inter block search 16x8
  332. * b8x16 : Enable inter block search 8x16
  333. * b8x8 : Enable inter block search 8x8
  334. * b8x4 : Enable inter block search 8x4
  335. * b4x8 : Enable inter block search 4x8
  336. * b4x4 : Enable inter block search 4x4
  337. */
  338. typedef struct OMX_VIDEO_PARAM_VBSMCTYPE {
  339. OMX_U32 nSize;
  340. OMX_VERSIONTYPE nVersion;
  341. OMX_U32 nPortIndex;
  342. OMX_BOOL b16x16;
  343. OMX_BOOL b16x8;
  344. OMX_BOOL b8x16;
  345. OMX_BOOL b8x8;
  346. OMX_BOOL b8x4;
  347. OMX_BOOL b4x8;
  348. OMX_BOOL b4x4;
  349. } OMX_VIDEO_PARAM_VBSMCTYPE;
  350. /**
  351. * H.263 profile types, each profile indicates support for various
  352. * performance bounds and different annexes.
  353. *
  354. * ENUMS:
  355. * Baseline : Baseline Profile: H.263 (V1), no optional modes
  356. * H320 Coding : H.320 Coding Efficiency Backward Compatibility
  357. * Profile: H.263+ (V2), includes annexes I, J, L.4
  358. * and T
  359. * BackwardCompatible : Backward Compatibility Profile: H.263 (V1),
  360. * includes annex F
  361. * ISWV2 : Interactive Streaming Wireless Profile: H.263+
  362. * (V2), includes annexes I, J, K and T
  363. * ISWV3 : Interactive Streaming Wireless Profile: H.263++
  364. * (V3), includes profile 3 and annexes V and W.6.3.8
  365. * HighCompression : Conversational High Compression Profile: H.263++
  366. * (V3), includes profiles 1 & 2 and annexes D and U
  367. * Internet : Conversational Internet Profile: H.263++ (V3),
  368. * includes profile 5 and annex K
  369. * Interlace : Conversational Interlace Profile: H.263++ (V3),
  370. * includes profile 5 and annex W.6.3.11
  371. * HighLatency : High Latency Profile: H.263++ (V3), includes
  372. * profile 6 and annexes O.1 and P.5
  373. */
  374. typedef enum OMX_VIDEO_H263PROFILETYPE {
  375. OMX_VIDEO_H263ProfileBaseline = 0x01,
  376. OMX_VIDEO_H263ProfileH320Coding = 0x02,
  377. OMX_VIDEO_H263ProfileBackwardCompatible = 0x04,
  378. OMX_VIDEO_H263ProfileISWV2 = 0x08,
  379. OMX_VIDEO_H263ProfileISWV3 = 0x10,
  380. OMX_VIDEO_H263ProfileHighCompression = 0x20,
  381. OMX_VIDEO_H263ProfileInternet = 0x40,
  382. OMX_VIDEO_H263ProfileInterlace = 0x80,
  383. OMX_VIDEO_H263ProfileHighLatency = 0x100,
  384. OMX_VIDEO_H263ProfileKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  385. OMX_VIDEO_H263ProfileVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  386. OMX_VIDEO_H263ProfileMax = 0x7FFFFFFF
  387. } OMX_VIDEO_H263PROFILETYPE;
  388. /**
  389. * H.263 level types, each level indicates support for various frame sizes,
  390. * bit rates, decoder frame rates.
  391. */
  392. typedef enum OMX_VIDEO_H263LEVELTYPE {
  393. OMX_VIDEO_H263Level10 = 0x01,
  394. OMX_VIDEO_H263Level20 = 0x02,
  395. OMX_VIDEO_H263Level30 = 0x04,
  396. OMX_VIDEO_H263Level40 = 0x08,
  397. OMX_VIDEO_H263Level45 = 0x10,
  398. OMX_VIDEO_H263Level50 = 0x20,
  399. OMX_VIDEO_H263Level60 = 0x40,
  400. OMX_VIDEO_H263Level70 = 0x80,
  401. OMX_VIDEO_H263LevelKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  402. OMX_VIDEO_H263LevelVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  403. OMX_VIDEO_H263LevelMax = 0x7FFFFFFF
  404. } OMX_VIDEO_H263LEVELTYPE;
  405. /**
  406. * Specifies the picture type. These values should be OR'd to signal all
  407. * pictures types which are allowed.
  408. *
  409. * ENUMS:
  410. * Generic Picture Types: I, P and B
  411. * H.263 Specific Picture Types: SI and SP
  412. * H.264 Specific Picture Types: EI and EP
  413. * MPEG-4 Specific Picture Types: S
  414. */
  415. typedef enum OMX_VIDEO_PICTURETYPE {
  416. OMX_VIDEO_PictureTypeI = 0x01,
  417. OMX_VIDEO_PictureTypeP = 0x02,
  418. OMX_VIDEO_PictureTypeB = 0x04,
  419. OMX_VIDEO_PictureTypeSI = 0x08,
  420. OMX_VIDEO_PictureTypeSP = 0x10,
  421. OMX_VIDEO_PictureTypeEI = 0x11,
  422. OMX_VIDEO_PictureTypeEP = 0x12,
  423. OMX_VIDEO_PictureTypeS = 0x14,
  424. OMX_VIDEO_PictureTypeKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  425. OMX_VIDEO_PictureTypeVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  426. OMX_VIDEO_PictureTypeMax = 0x7FFFFFFF
  427. } OMX_VIDEO_PICTURETYPE;
  428. /**
  429. * H.263 Params
  430. *
  431. * STRUCT MEMBERS:
  432. * nSize : Size of the structure in bytes
  433. * nVersion : OMX specification version information
  434. * nPortIndex : Port that this structure applies to
  435. * nPFrames : Number of P frames between each I frame
  436. * nBFrames : Number of B frames between each I frame
  437. * eProfile : H.263 profile(s) to use
  438. * eLevel : H.263 level(s) to use
  439. * bPLUSPTYPEAllowed : Indicating that it is allowed to use PLUSPTYPE
  440. * (specified in the 1998 version of H.263) to
  441. * indicate custom picture sizes or clock
  442. * frequencies
  443. * nAllowedPictureTypes : Specifies the picture types allowed in the
  444. * bitstream
  445. * bForceRoundingTypeToZero : value of the RTYPE bit (bit 6 of MPPTYPE) is
  446. * not constrained. It is recommended to change
  447. * the value of the RTYPE bit for each reference
  448. * picture in error-free communication
  449. * nPictureHeaderRepetition : Specifies the frequency of picture header
  450. * repetition
  451. * nGOBHeaderInterval : Specifies the interval of non-empty GOB
  452. * headers in units of GOBs
  453. */
  454. typedef struct OMX_VIDEO_PARAM_H263TYPE {
  455. OMX_U32 nSize;
  456. OMX_VERSIONTYPE nVersion;
  457. OMX_U32 nPortIndex;
  458. OMX_U32 nPFrames;
  459. OMX_U32 nBFrames;
  460. OMX_VIDEO_H263PROFILETYPE eProfile;
  461. OMX_VIDEO_H263LEVELTYPE eLevel;
  462. OMX_BOOL bPLUSPTYPEAllowed;
  463. OMX_U32 nAllowedPictureTypes;
  464. OMX_BOOL bForceRoundingTypeToZero;
  465. OMX_U32 nPictureHeaderRepetition;
  466. OMX_U32 nGOBHeaderInterval;
  467. } OMX_VIDEO_PARAM_H263TYPE;
  468. /**
  469. * MPEG-2 profile types, each profile indicates support for various
  470. * performance bounds and different annexes.
  471. */
  472. typedef enum OMX_VIDEO_MPEG2PROFILETYPE {
  473. OMX_VIDEO_MPEG2ProfileSimple = 0, /**< Simple Profile */
  474. OMX_VIDEO_MPEG2ProfileMain, /**< Main Profile */
  475. OMX_VIDEO_MPEG2Profile422, /**< 4:2:2 Profile */
  476. OMX_VIDEO_MPEG2ProfileSNR, /**< SNR Profile */
  477. OMX_VIDEO_MPEG2ProfileSpatial, /**< Spatial Profile */
  478. OMX_VIDEO_MPEG2ProfileHigh, /**< High Profile */
  479. OMX_VIDEO_MPEG2ProfileKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  480. OMX_VIDEO_MPEG2ProfileVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  481. OMX_VIDEO_MPEG2ProfileMax = 0x7FFFFFFF
  482. } OMX_VIDEO_MPEG2PROFILETYPE;
  483. /**
  484. * MPEG-2 level types, each level indicates support for various frame
  485. * sizes, bit rates, decoder frame rates. No need
  486. */
  487. typedef enum OMX_VIDEO_MPEG2LEVELTYPE {
  488. OMX_VIDEO_MPEG2LevelLL = 0, /**< Low Level */
  489. OMX_VIDEO_MPEG2LevelML, /**< Main Level */
  490. OMX_VIDEO_MPEG2LevelH14, /**< High 1440 */
  491. OMX_VIDEO_MPEG2LevelHL, /**< High Level */
  492. OMX_VIDEO_MPEG2LevelKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  493. OMX_VIDEO_MPEG2LevelVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  494. OMX_VIDEO_MPEG2LevelMax = 0x7FFFFFFF
  495. } OMX_VIDEO_MPEG2LEVELTYPE;
  496. /**
  497. * MPEG-2 params
  498. *
  499. * STRUCT MEMBERS:
  500. * nSize : Size of the structure in bytes
  501. * nVersion : OMX specification version information
  502. * nPortIndex : Port that this structure applies to
  503. * nPFrames : Number of P frames between each I frame
  504. * nBFrames : Number of B frames between each I frame
  505. * eProfile : MPEG-2 profile(s) to use
  506. * eLevel : MPEG-2 levels(s) to use
  507. */
  508. typedef struct OMX_VIDEO_PARAM_MPEG2TYPE {
  509. OMX_U32 nSize;
  510. OMX_VERSIONTYPE nVersion;
  511. OMX_U32 nPortIndex;
  512. OMX_U32 nPFrames;
  513. OMX_U32 nBFrames;
  514. OMX_VIDEO_MPEG2PROFILETYPE eProfile;
  515. OMX_VIDEO_MPEG2LEVELTYPE eLevel;
  516. } OMX_VIDEO_PARAM_MPEG2TYPE;
  517. /**
  518. * MPEG-4 profile types, each profile indicates support for various
  519. * performance bounds and different annexes.
  520. *
  521. * ENUMS:
  522. * - Simple Profile, Levels 1-3
  523. * - Simple Scalable Profile, Levels 1-2
  524. * - Core Profile, Levels 1-2
  525. * - Main Profile, Levels 2-4
  526. * - N-bit Profile, Level 2
  527. * - Scalable Texture Profile, Level 1
  528. * - Simple Face Animation Profile, Levels 1-2
  529. * - Simple Face and Body Animation (FBA) Profile, Levels 1-2
  530. * - Basic Animated Texture Profile, Levels 1-2
  531. * - Hybrid Profile, Levels 1-2
  532. * - Advanced Real Time Simple Profiles, Levels 1-4
  533. * - Core Scalable Profile, Levels 1-3
  534. * - Advanced Coding Efficiency Profile, Levels 1-4
  535. * - Advanced Core Profile, Levels 1-2
  536. * - Advanced Scalable Texture, Levels 2-3
  537. */
  538. typedef enum OMX_VIDEO_MPEG4PROFILETYPE {
  539. OMX_VIDEO_MPEG4ProfileSimple = 0x01,
  540. OMX_VIDEO_MPEG4ProfileSimpleScalable = 0x02,
  541. OMX_VIDEO_MPEG4ProfileCore = 0x04,
  542. OMX_VIDEO_MPEG4ProfileMain = 0x08,
  543. OMX_VIDEO_MPEG4ProfileNbit = 0x10,
  544. OMX_VIDEO_MPEG4ProfileScalableTexture = 0x20,
  545. OMX_VIDEO_MPEG4ProfileSimpleFace = 0x40,
  546. OMX_VIDEO_MPEG4ProfileSimpleFBA = 0x80,
  547. OMX_VIDEO_MPEG4ProfileBasicAnimated = 0x100,
  548. OMX_VIDEO_MPEG4ProfileHybrid = 0x200,
  549. OMX_VIDEO_MPEG4ProfileAdvancedRealTime = 0x400,
  550. OMX_VIDEO_MPEG4ProfileCoreScalable = 0x800,
  551. OMX_VIDEO_MPEG4ProfileAdvancedCoding = 0x1000,
  552. OMX_VIDEO_MPEG4ProfileAdvancedCore = 0x2000,
  553. OMX_VIDEO_MPEG4ProfileAdvancedScalable = 0x4000,
  554. OMX_VIDEO_MPEG4ProfileAdvancedSimple = 0x8000,
  555. OMX_VIDEO_MPEG4ProfileKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  556. OMX_VIDEO_MPEG4ProfileVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  557. OMX_VIDEO_MPEG4ProfileMax = 0x7FFFFFFF
  558. } OMX_VIDEO_MPEG4PROFILETYPE;
  559. /**
  560. * MPEG-4 level types, each level indicates support for various frame
  561. * sizes, bit rates, decoder frame rates. No need
  562. */
  563. typedef enum OMX_VIDEO_MPEG4LEVELTYPE {
  564. OMX_VIDEO_MPEG4Level0 = 0x01, /**< Level 0 */
  565. OMX_VIDEO_MPEG4Level0b = 0x02, /**< Level 0b */
  566. OMX_VIDEO_MPEG4Level1 = 0x04, /**< Level 1 */
  567. OMX_VIDEO_MPEG4Level2 = 0x08, /**< Level 2 */
  568. OMX_VIDEO_MPEG4Level3 = 0x10, /**< Level 3 */
  569. OMX_VIDEO_MPEG4Level4 = 0x20, /**< Level 4 */
  570. OMX_VIDEO_MPEG4Level4a = 0x40, /**< Level 4a */
  571. OMX_VIDEO_MPEG4Level5 = 0x80, /**< Level 5 */
  572. OMX_VIDEO_MPEG4LevelKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  573. OMX_VIDEO_MPEG4LevelVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  574. OMX_VIDEO_MPEG4LevelMax = 0x7FFFFFFF
  575. } OMX_VIDEO_MPEG4LEVELTYPE;
  576. /**
  577. * MPEG-4 configuration. This structure handles configuration options
  578. * which are specific to MPEG4 algorithms
  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. * nSliceHeaderSpacing : Number of macroblocks between slice header (H263+
  585. * Annex K). Put zero if not used
  586. * bSVH : Enable Short Video Header mode
  587. * bGov : Flag to enable GOV
  588. * nPFrames : Number of P frames between each I frame (also called
  589. * GOV period)
  590. * nBFrames : Number of B frames between each I frame
  591. * nIDCVLCThreshold : Value of intra DC VLC threshold
  592. * bACPred : Flag to use ac prediction
  593. * nMaxPacketSize : Maximum size of packet in bytes.
  594. * nTimeIncRes : Used to pass VOP time increment resolution for MPEG4.
  595. * Interpreted as described in MPEG4 standard.
  596. * eProfile : MPEG-4 profile(s) to use.
  597. * eLevel : MPEG-4 level(s) to use.
  598. * nAllowedPictureTypes : Specifies the picture types allowed in the bitstream
  599. * nHeaderExtension : Specifies the number of consecutive video packet
  600. * headers within a VOP
  601. * bReversibleVLC : Specifies whether reversible variable length coding
  602. * is in use
  603. */
  604. typedef struct OMX_VIDEO_PARAM_MPEG4TYPE {
  605. OMX_U32 nSize;
  606. OMX_VERSIONTYPE nVersion;
  607. OMX_U32 nPortIndex;
  608. OMX_U32 nSliceHeaderSpacing;
  609. OMX_BOOL bSVH;
  610. OMX_BOOL bGov;
  611. OMX_U32 nPFrames;
  612. OMX_U32 nBFrames;
  613. OMX_U32 nIDCVLCThreshold;
  614. OMX_BOOL bACPred;
  615. OMX_U32 nMaxPacketSize;
  616. OMX_U32 nTimeIncRes;
  617. OMX_VIDEO_MPEG4PROFILETYPE eProfile;
  618. OMX_VIDEO_MPEG4LEVELTYPE eLevel;
  619. OMX_U32 nAllowedPictureTypes;
  620. OMX_U32 nHeaderExtension;
  621. OMX_BOOL bReversibleVLC;
  622. } OMX_VIDEO_PARAM_MPEG4TYPE;
  623. /**
  624. * WMV Versions
  625. */
  626. typedef enum OMX_VIDEO_WMVFORMATTYPE {
  627. OMX_VIDEO_WMVFormatUnused = 0x01, /**< Format unused or unknown */
  628. OMX_VIDEO_WMVFormat7 = 0x02, /**< Windows Media Video format 7 */
  629. OMX_VIDEO_WMVFormat8 = 0x04, /**< Windows Media Video format 8 */
  630. OMX_VIDEO_WMVFormat9 = 0x08, /**< Windows Media Video format 9 */
  631. OMX_VIDEO_WMFFormatKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  632. OMX_VIDEO_WMFFormatVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  633. OMX_VIDEO_WMVFormatMax = 0x7FFFFFFF
  634. } OMX_VIDEO_WMVFORMATTYPE;
  635. /**
  636. * WMV Params
  637. *
  638. * STRUCT MEMBERS:
  639. * nSize : Size of the structure in bytes
  640. * nVersion : OMX specification version information
  641. * nPortIndex : Port that this structure applies to
  642. * eFormat : Version of WMV stream / data
  643. */
  644. typedef struct OMX_VIDEO_PARAM_WMVTYPE {
  645. OMX_U32 nSize;
  646. OMX_VERSIONTYPE nVersion;
  647. OMX_U32 nPortIndex;
  648. OMX_VIDEO_WMVFORMATTYPE eFormat;
  649. } OMX_VIDEO_PARAM_WMVTYPE;
  650. /**
  651. * Real Video Version
  652. */
  653. typedef enum OMX_VIDEO_RVFORMATTYPE {
  654. OMX_VIDEO_RVFormatUnused = 0, /**< Format unused or unknown */
  655. OMX_VIDEO_RVFormat8, /**< Real Video format 8 */
  656. OMX_VIDEO_RVFormat9, /**< Real Video format 9 */
  657. OMX_VIDEO_RVFormatG2, /**< Real Video Format G2 */
  658. OMX_VIDEO_RVFormatKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  659. OMX_VIDEO_RVFormatVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  660. OMX_VIDEO_RVFormatMax = 0x7FFFFFFF
  661. } OMX_VIDEO_RVFORMATTYPE;
  662. /**
  663. * Real Video Params
  664. *
  665. * STUCT MEMBERS:
  666. * nSize : Size of the structure in bytes
  667. * nVersion : OMX specification version information
  668. * nPortIndex : Port that this structure applies to
  669. * eFormat : Version of RV stream / data
  670. * nBitsPerPixel : Bits per pixel coded in the frame
  671. * nPaddedWidth : Padded width in pixel of a video frame
  672. * nPaddedHeight : Padded Height in pixels of a video frame
  673. * nFrameRate : Rate of video in frames per second
  674. * nBitstreamFlags : Flags which internal information about the bitstream
  675. * nBitstreamVersion : Bitstream version
  676. * nMaxEncodeFrameSize: Max encoded frame size
  677. * bEnablePostFilter : Turn on/off post filter
  678. * bEnableTemporalInterpolation : Turn on/off temporal interpolation
  679. * bEnableLatencyMode : When enabled, the decoder does not display a decoded
  680. * frame until it has detected that no enhancement layer
  681. * frames or dependent B frames will be coming. This
  682. * detection usually occurs when a subsequent non-B
  683. * frame is encountered
  684. */
  685. typedef struct OMX_VIDEO_PARAM_RVTYPE {
  686. OMX_U32 nSize;
  687. OMX_VERSIONTYPE nVersion;
  688. OMX_U32 nPortIndex;
  689. OMX_VIDEO_RVFORMATTYPE eFormat;
  690. OMX_U16 nBitsPerPixel;
  691. OMX_U16 nPaddedWidth;
  692. OMX_U16 nPaddedHeight;
  693. OMX_U32 nFrameRate;
  694. OMX_U32 nBitstreamFlags;
  695. OMX_U32 nBitstreamVersion;
  696. OMX_U32 nMaxEncodeFrameSize;
  697. OMX_BOOL bEnablePostFilter;
  698. OMX_BOOL bEnableTemporalInterpolation;
  699. OMX_BOOL bEnableLatencyMode;
  700. } OMX_VIDEO_PARAM_RVTYPE;
  701. /**
  702. * AVC profile types, each profile indicates support for various
  703. * performance bounds and different annexes.
  704. */
  705. typedef enum OMX_VIDEO_AVCPROFILETYPE {
  706. OMX_VIDEO_AVCProfileBaseline = 0x01, /**< Baseline profile */
  707. OMX_VIDEO_AVCProfileMain = 0x02, /**< Main profile */
  708. OMX_VIDEO_AVCProfileExtended = 0x04, /**< Extended profile */
  709. OMX_VIDEO_AVCProfileHigh = 0x08, /**< High profile */
  710. OMX_VIDEO_AVCProfileHigh10 = 0x10, /**< High 10 profile */
  711. OMX_VIDEO_AVCProfileHigh422 = 0x20, /**< High 4:2:2 profile */
  712. OMX_VIDEO_AVCProfileHigh444 = 0x40, /**< High 4:4:4 profile */
  713. OMX_VIDEO_AVCProfileKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  714. OMX_VIDEO_AVCProfileVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  715. OMX_VIDEO_AVCProfileMax = 0x7FFFFFFF
  716. } OMX_VIDEO_AVCPROFILETYPE;
  717. /**
  718. * AVC level types, each level indicates support for various frame sizes,
  719. * bit rates, decoder frame rates. No need
  720. */
  721. typedef enum OMX_VIDEO_AVCLEVELTYPE {
  722. OMX_VIDEO_AVCLevel1 = 0x01, /**< Level 1 */
  723. OMX_VIDEO_AVCLevel1b = 0x02, /**< Level 1b */
  724. OMX_VIDEO_AVCLevel11 = 0x04, /**< Level 1.1 */
  725. OMX_VIDEO_AVCLevel12 = 0x08, /**< Level 1.2 */
  726. OMX_VIDEO_AVCLevel13 = 0x10, /**< Level 1.3 */
  727. OMX_VIDEO_AVCLevel2 = 0x20, /**< Level 2 */
  728. OMX_VIDEO_AVCLevel21 = 0x40, /**< Level 2.1 */
  729. OMX_VIDEO_AVCLevel22 = 0x80, /**< Level 2.2 */
  730. OMX_VIDEO_AVCLevel3 = 0x100, /**< Level 3 */
  731. OMX_VIDEO_AVCLevel31 = 0x200, /**< Level 3.1 */
  732. OMX_VIDEO_AVCLevel32 = 0x400, /**< Level 3.2 */
  733. OMX_VIDEO_AVCLevel4 = 0x800, /**< Level 4 */
  734. OMX_VIDEO_AVCLevel41 = 0x1000, /**< Level 4.1 */
  735. OMX_VIDEO_AVCLevel42 = 0x2000, /**< Level 4.2 */
  736. OMX_VIDEO_AVCLevel5 = 0x4000, /**< Level 5 */
  737. OMX_VIDEO_AVCLevel51 = 0x8000, /**< Level 5.1 */
  738. OMX_VIDEO_AVCLevelKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  739. OMX_VIDEO_AVCLevelVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  740. OMX_VIDEO_AVCLevelMax = 0x7FFFFFFF
  741. } OMX_VIDEO_AVCLEVELTYPE;
  742. /**
  743. * AVC loop filter modes
  744. *
  745. * OMX_VIDEO_AVCLoopFilterEnable : Enable
  746. * OMX_VIDEO_AVCLoopFilterDisable : Disable
  747. * OMX_VIDEO_AVCLoopFilterDisableSliceBoundary : Disabled on slice boundaries
  748. */
  749. typedef enum OMX_VIDEO_AVCLOOPFILTERTYPE {
  750. OMX_VIDEO_AVCLoopFilterEnable = 0,
  751. OMX_VIDEO_AVCLoopFilterDisable,
  752. OMX_VIDEO_AVCLoopFilterDisableSliceBoundary,
  753. OMX_VIDEO_AVCLoopFilterKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  754. OMX_VIDEO_AVCLoopFilterVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  755. OMX_VIDEO_AVCLoopFilterMax = 0x7FFFFFFF
  756. } OMX_VIDEO_AVCLOOPFILTERTYPE;
  757. /**
  758. * AVC params
  759. *
  760. * STRUCT MEMBERS:
  761. * nSize : Size of the structure in bytes
  762. * nVersion : OMX specification version information
  763. * nPortIndex : Port that this structure applies to
  764. * nSliceHeaderSpacing : Number of macroblocks between slice header, put
  765. * zero if not used
  766. * nPFrames : Number of P frames between each I frame
  767. * nBFrames : Number of B frames between each I frame
  768. * bUseHadamard : Enable/disable Hadamard transform
  769. * nRefFrames : Max number of reference frames to use for inter
  770. * motion search (1-16)
  771. * nRefIdxTrailing : Pic param set ref frame index (index into ref
  772. * frame buffer of trailing frames list), B frame
  773. * support
  774. * nRefIdxForward : Pic param set ref frame index (index into ref
  775. * frame buffer of forward frames list), B frame
  776. * support
  777. * bEnableUEP : Enable/disable unequal error protection. This
  778. * is only valid of data partitioning is enabled.
  779. * bEnableFMO : Enable/disable flexible macroblock ordering
  780. * bEnableASO : Enable/disable arbitrary slice ordering
  781. * bEnableRS : Enable/disable sending of redundant slices
  782. * eProfile : AVC profile(s) to use
  783. * eLevel : AVC level(s) to use
  784. * nAllowedPictureTypes : Specifies the picture types allowed in the
  785. * bitstream
  786. * bFrameMBsOnly : specifies that every coded picture of the
  787. * coded video sequence is a coded frame
  788. * containing only frame macroblocks
  789. * bMBAFF : Enable/disable switching between frame and
  790. * field macroblocks within a picture
  791. * bEntropyCodingCABAC : Entropy decoding method to be applied for the
  792. * syntax elements for which two descriptors appear
  793. * in the syntax tables
  794. * bWeightedPPrediction : Enable/disable weighted prediction shall not
  795. * be applied to P and SP slices
  796. * nWeightedBipredicitonMode : Default weighted prediction is applied to B
  797. * slices
  798. * bconstIpred : Enable/disable intra prediction
  799. * bDirect8x8Inference : Specifies the method used in the derivation
  800. * process for luma motion vectors for B_Skip,
  801. * B_Direct_16x16 and B_Direct_8x8 as specified
  802. * in subclause 8.4.1.2 of the AVC spec
  803. * bDirectSpatialTemporal : Flag indicating spatial or temporal direct
  804. * mode used in B slice coding (related to
  805. * bDirect8x8Inference) . Spatial direct mode is
  806. * more common and should be the default.
  807. * nCabacInitIdx : Index used to init CABAC contexts
  808. * eLoopFilterMode : Enable/disable loop filter
  809. */
  810. typedef struct OMX_VIDEO_PARAM_AVCTYPE {
  811. OMX_U32 nSize;
  812. OMX_VERSIONTYPE nVersion;
  813. OMX_U32 nPortIndex;
  814. OMX_U32 nSliceHeaderSpacing;
  815. OMX_U32 nPFrames;
  816. OMX_U32 nBFrames;
  817. OMX_BOOL bUseHadamard;
  818. OMX_U32 nRefFrames;
  819. OMX_U32 nRefIdx10ActiveMinus1;
  820. OMX_U32 nRefIdx11ActiveMinus1;
  821. OMX_BOOL bEnableUEP;
  822. OMX_BOOL bEnableFMO;
  823. OMX_BOOL bEnableASO;
  824. OMX_BOOL bEnableRS;
  825. OMX_VIDEO_AVCPROFILETYPE eProfile;
  826. OMX_VIDEO_AVCLEVELTYPE eLevel;
  827. OMX_U32 nAllowedPictureTypes;
  828. OMX_BOOL bFrameMBsOnly;
  829. OMX_BOOL bMBAFF;
  830. OMX_BOOL bEntropyCodingCABAC;
  831. OMX_BOOL bWeightedPPrediction;
  832. OMX_U32 nWeightedBipredicitonMode;
  833. OMX_BOOL bconstIpred ;
  834. OMX_BOOL bDirect8x8Inference;
  835. OMX_BOOL bDirectSpatialTemporal;
  836. OMX_U32 nCabacInitIdc;
  837. OMX_VIDEO_AVCLOOPFILTERTYPE eLoopFilterMode;
  838. } OMX_VIDEO_PARAM_AVCTYPE;
  839. typedef struct OMX_VIDEO_PARAM_PROFILELEVELTYPE {
  840. OMX_U32 nSize;
  841. OMX_VERSIONTYPE nVersion;
  842. OMX_U32 nPortIndex;
  843. OMX_U32 eProfile; /**< type is OMX_VIDEO_AVCPROFILETYPE, OMX_VIDEO_H263PROFILETYPE,
  844. or OMX_VIDEO_MPEG4PROFILETYPE depending on context */
  845. OMX_U32 eLevel; /**< type is OMX_VIDEO_AVCLEVELTYPE, OMX_VIDEO_H263LEVELTYPE,
  846. or OMX_VIDEO_MPEG4PROFILETYPE depending on context */
  847. OMX_U32 nProfileIndex; /**< Used to query for individual profile support information,
  848. This parameter is valid only for
  849. OMX_IndexParamVideoProfileLevelQuerySupported index,
  850. For all other indices this parameter is to be ignored. */
  851. } OMX_VIDEO_PARAM_PROFILELEVELTYPE;
  852. /**
  853. * Structure for dynamically configuring bitrate mode of a codec.
  854. *
  855. * STRUCT MEMBERS:
  856. * nSize : Size of the struct in bytes
  857. * nVersion : OMX spec version info
  858. * nPortIndex : Port that this struct applies to
  859. * nEncodeBitrate : Target average bitrate to be generated in bps
  860. */
  861. typedef struct OMX_VIDEO_CONFIG_BITRATETYPE {
  862. OMX_U32 nSize;
  863. OMX_VERSIONTYPE nVersion;
  864. OMX_U32 nPortIndex;
  865. OMX_U32 nEncodeBitrate;
  866. } OMX_VIDEO_CONFIG_BITRATETYPE;
  867. /**
  868. * Defines Encoder Frame Rate setting
  869. *
  870. * STRUCT MEMBERS:
  871. * nSize : Size of the structure in bytes
  872. * nVersion : OMX specification version information
  873. * nPortIndex : Port that this structure applies to
  874. * xEncodeFramerate : Encoding framerate represented in Q16 format
  875. */
  876. typedef struct OMX_CONFIG_FRAMERATETYPE {
  877. OMX_U32 nSize;
  878. OMX_VERSIONTYPE nVersion;
  879. OMX_U32 nPortIndex;
  880. OMX_U32 xEncodeFramerate; /* Q16 format */
  881. } OMX_CONFIG_FRAMERATETYPE;
  882. typedef struct OMX_CONFIG_INTRAREFRESHVOPTYPE {
  883. OMX_U32 nSize;
  884. OMX_VERSIONTYPE nVersion;
  885. OMX_U32 nPortIndex;
  886. OMX_BOOL IntraRefreshVOP;
  887. } OMX_CONFIG_INTRAREFRESHVOPTYPE;
  888. typedef struct OMX_CONFIG_MACROBLOCKERRORMAPTYPE {
  889. OMX_U32 nSize;
  890. OMX_VERSIONTYPE nVersion;
  891. OMX_U32 nPortIndex;
  892. OMX_U32 nErrMapSize; /* Size of the Error Map in bytes */
  893. OMX_U8 ErrMap[1]; /* Error map hint */
  894. } OMX_CONFIG_MACROBLOCKERRORMAPTYPE;
  895. typedef struct OMX_CONFIG_MBERRORREPORTINGTYPE {
  896. OMX_U32 nSize;
  897. OMX_VERSIONTYPE nVersion;
  898. OMX_U32 nPortIndex;
  899. OMX_BOOL bEnabled;
  900. } OMX_CONFIG_MBERRORREPORTINGTYPE;
  901. typedef struct OMX_PARAM_MACROBLOCKSTYPE {
  902. OMX_U32 nSize;
  903. OMX_VERSIONTYPE nVersion;
  904. OMX_U32 nPortIndex;
  905. OMX_U32 nMacroblocks;
  906. } OMX_PARAM_MACROBLOCKSTYPE;
  907. /**
  908. * AVC Slice Mode modes
  909. *
  910. * OMX_VIDEO_SLICEMODE_AVCDefault : Normal frame encoding, one slice per frame
  911. * OMX_VIDEO_SLICEMODE_AVCMBSlice : NAL mode, number of MBs per frame
  912. * OMX_VIDEO_SLICEMODE_AVCByteSlice : NAL mode, number of bytes per frame
  913. */
  914. typedef enum OMX_VIDEO_AVCSLICEMODETYPE {
  915. OMX_VIDEO_SLICEMODE_AVCDefault = 0,
  916. OMX_VIDEO_SLICEMODE_AVCMBSlice,
  917. OMX_VIDEO_SLICEMODE_AVCByteSlice,
  918. OMX_VIDEO_SLICEMODE_AVCKhronosExtensions = 0x6F000000, /**< Reserved region for introducing Khronos Standard Extensions */
  919. OMX_VIDEO_SLICEMODE_AVCVendorStartUnused = 0x7F000000, /**< Reserved region for introducing Vendor Extensions */
  920. OMX_VIDEO_SLICEMODE_AVCLevelMax = 0x7FFFFFFF
  921. } OMX_VIDEO_AVCSLICEMODETYPE;
  922. /**
  923. * AVC FMO Slice Mode Params
  924. *
  925. * STRUCT MEMBERS:
  926. * nSize : Size of the structure in bytes
  927. * nVersion : OMX specification version information
  928. * nPortIndex : Port that this structure applies to
  929. * nNumSliceGroups : Specifies the number of slice groups
  930. * nSliceGroupMapType : Specifies the type of slice groups
  931. * eSliceMode : Specifies the type of slice
  932. */
  933. typedef struct OMX_VIDEO_PARAM_AVCSLICEFMO {
  934. OMX_U32 nSize;
  935. OMX_VERSIONTYPE nVersion;
  936. OMX_U32 nPortIndex;
  937. OMX_U8 nNumSliceGroups;
  938. OMX_U8 nSliceGroupMapType;
  939. OMX_VIDEO_AVCSLICEMODETYPE eSliceMode;
  940. } OMX_VIDEO_PARAM_AVCSLICEFMO;
  941. /**
  942. * AVC IDR Period Configs
  943. *
  944. * STRUCT MEMBERS:
  945. * nSize : Size of the structure in bytes
  946. * nVersion : OMX specification version information
  947. * nPortIndex : Port that this structure applies to
  948. * nIDRPeriod : Specifies periodicity of IDR frames
  949. * nPFrames : Specifies internal of coding Intra frames
  950. */
  951. typedef struct OMX_VIDEO_CONFIG_AVCINTRAPERIOD {
  952. OMX_U32 nSize;
  953. OMX_VERSIONTYPE nVersion;
  954. OMX_U32 nPortIndex;
  955. OMX_U32 nIDRPeriod;
  956. OMX_U32 nPFrames;
  957. } OMX_VIDEO_CONFIG_AVCINTRAPERIOD;
  958. /**
  959. * AVC NAL Size Configs
  960. *
  961. * STRUCT MEMBERS:
  962. * nSize : Size of the structure in bytes
  963. * nVersion : OMX specification version information
  964. * nPortIndex : Port that this structure applies to
  965. * nNaluBytes : Specifies the NAL unit size
  966. */
  967. typedef struct OMX_VIDEO_CONFIG_NALSIZE {
  968. OMX_U32 nSize;
  969. OMX_VERSIONTYPE nVersion;
  970. OMX_U32 nPortIndex;
  971. OMX_U32 nNaluBytes;
  972. } OMX_VIDEO_CONFIG_NALSIZE;
  973. /** @} */
  974. #ifdef __cplusplus
  975. }
  976. #endif /* __cplusplus */
  977. #endif
  978. /* File EOF */