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