1826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/* 2826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Copyright (c) 2008 The Khronos Group Inc. 36eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * 4826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Permission is hereby granted, free of charge, to any person obtaining 5826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * a copy of this software and associated documentation files (the 6826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * "Software"), to deal in the Software without restriction, including 7826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * without limitation the rights to use, copy, modify, merge, publish, 8826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * distribute, sublicense, and/or sell copies of the Software, and to 9826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * permit persons to whom the Software is furnished to do so, subject 10826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * to the following conditions: 11826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * The above copyright notice and this permission notice shall be included 12826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * in all copies or substantial portions of the Software. 136eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * 14826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 15826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 16826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 17826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 18826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 19826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 20826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * 22826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 23826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 24826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_Types.h - OpenMax IL version 1.1.2 25826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * The OMX_Types header file contains the primitive type definitions used by 26826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * the core, the application and the component. This file may need to be 276eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * modified to be used on systems that do not have "char" set to 8 bits, 28826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * "short" set to 16 bits and "long" set to 32 bits. 29826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 30826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 31826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_Types_h 32826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_Types_h 33826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 34826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifdef __cplusplus 35826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevextern "C" { 36826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif /* __cplusplus */ 37826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 38826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_API and OMX_APIENTRY are platform specific definitions used 39826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * to declare OMX function prototypes. They are modified to meet the 40826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * requirements for a particular platform */ 41826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifdef __SYMBIAN32__ 42826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# ifdef __OMX_EXPORTS 43826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API __declspec(dllexport) 44826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# else 45826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# ifdef _WIN32 46826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API __declspec(dllexport) 47826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# else 48826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API __declspec(dllimport) 49826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# endif 50826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# endif 51826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#else 52826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# ifdef _WIN32 53826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# ifdef __OMX_EXPORTS 54826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API __declspec(dllexport) 55826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# else 56826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API __declspec(dllimport) 57826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# endif 58826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# else 59826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# ifdef __OMX_EXPORTS 60826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API 61826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# else 62826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# define OMX_API extern 63826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# endif 64826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev# endif 65826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 66826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 67826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_APIENTRY 68826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_APIENTRY 69826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 70826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 71826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_IN is used to identify inputs to an OMX function. This designation 72826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev will also be used in the case of a pointer that points to a parameter 73826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev that is used as an output. */ 74826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_IN 75826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_IN 76826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 77826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 78826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_OUT is used to identify outputs from an OMX function. This 79826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev designation will also be used in the case of a pointer that points 80826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev to a parameter that is used as an input. */ 81826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_OUT 82826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_OUT 83826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 84826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 85826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 86826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_INOUT is used to identify parameters that may be either inputs or 87826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev outputs from an OMX function at the same time. This designation will 88826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev also be used in the case of a pointer that points to a parameter that 89826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev is used both as an input and an output. */ 90826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_INOUT 91826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_INOUT 92826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 93826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 94826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_ALL is used to as a wildcard to select all entities of the same type 95826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * when specifying the index, or referring to a object by an index. (i.e. 96826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * use OMX_ALL to indicate all N channels). When used as a port index 97826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * for a config or parameter this OMX_ALL denotes that the config or 98826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * parameter applies to the entire component not just one port. */ 99826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_ALL 0xFFFFFFFF 100826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 101826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** In the following we define groups that help building doxygen documentation */ 102826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 103826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** @defgroup core OpenMAX IL core 104826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Functions and structure related to the OMX IL core 105826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 1066eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 107826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev /** @defgroup comp OpenMAX IL component 108826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Functions and structure related to the OMX IL component 109826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 1106eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 111826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** @defgroup rpm Resource and Policy Management 112826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Structures for resource and policy management of components 113826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 114826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 115826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** @defgroup buf Buffer Management 116826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Buffer handling functions and structures 117826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 1186eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 119826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** @defgroup tun Tunneling 120826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * @ingroup core comp 121826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Structures and functions to manage tunnels among component ports 122826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 1236eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 124826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** @defgroup cp Content Pipes 125826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * @ingroup core 126826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 1276eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 128826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev /** @defgroup metadata Metadata handling 1296eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * 1306eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal */ 131826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 132826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U8 is an 8 bit unsigned quantity that is byte aligned */ 133826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned char OMX_U8; 134826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 135826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S8 is an 8 bit signed quantity that is byte aligned */ 136826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed char OMX_S8; 137826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 138826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U16 is a 16 bit unsigned quantity that is 16 bit word aligned */ 139826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned short OMX_U16; 140826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 141826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S16 is a 16 bit signed quantity that is 16 bit word aligned */ 142826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed short OMX_S16; 143826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 144826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U32 is a 32 bit unsigned quantity that is 32 bit word aligned */ 145826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned long OMX_U32; 146826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 147826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S32 is a 32 bit signed quantity that is 32 bit word aligned */ 148826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed long OMX_S32; 149826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 150826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 151826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/* Users with compilers that cannot accept the "long long" designation should 152826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev define the OMX_SKIP64BIT macro. It should be noted that this may cause 153826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev some components to fail to compile if the component was written to require 154826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 64 bit integral types. However, these components would NOT compile anyway 155826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev since the compiler does not support the way the component was written. 156826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev*/ 157826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_SKIP64BIT 158826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifdef __SYMBIAN32__ 159826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U64 is a 64 bit unsigned quantity that is 64 bit word aligned */ 160826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned long long OMX_U64; 161826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 162826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S64 is a 64 bit signed quantity that is 64 bit word aligned */ 163826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed long long OMX_S64; 164826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 165826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#elif defined(WIN32) 166826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 167826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U64 is a 64 bit unsigned quantity that is 64 bit word aligned */ 168826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned __int64 OMX_U64; 169826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 170826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S64 is a 64 bit signed quantity that is 64 bit word aligned */ 171826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed __int64 OMX_S64; 172826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 173826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#else /* WIN32 */ 174826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 175826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_U64 is a 64 bit unsigned quantity that is 64 bit word aligned */ 176826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned long long OMX_U64; 177826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 178826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_S64 is a 64 bit signed quantity that is 64 bit word aligned */ 179826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef signed long long OMX_S64; 180826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 181826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif /* WIN32 */ 182826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 183826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 184826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 185826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_BOOL type is intended to be used to represent a true or a false 186826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev value when passing parameters to and from the OMX core and components. The 187826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_BOOL is a 32 bit quantity and is aligned on a 32 bit word boundary. 188826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 189826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef enum OMX_BOOL { 190826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_FALSE = 0, 191826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_TRUE = !OMX_FALSE, 192826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_BOOL_MAX = 0x7FFFFFFF 193826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_BOOL; 1946eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal 195826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_PTR type is intended to be used to pass pointers between the OMX 196826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev applications and the OMX Core and components. This is a 32 bit pointer and 197826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev is aligned on a 32 bit boundary. 198826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 199826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef void* OMX_PTR; 200826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 201826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_STRING type is intended to be used to pass "C" type strings between 202826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev the application and the core and component. The OMX_STRING type is a 32 203826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev bit pointer to a zero terminated string. The pointer is word aligned and 204826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev the string is byte aligned. 205826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 206826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef char* OMX_STRING; 207826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 208826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_BYTE type is intended to be used to pass arrays of bytes such as 209826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev buffers between the application and the component and core. The OMX_BYTE 210826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev type is a 32 bit pointer to a zero terminated string. The pointer is word 211826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev aligned and the string is byte aligned. 212826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 213826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned char* OMX_BYTE; 214826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 215826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_UUIDTYPE is a very long unique identifier to uniquely identify 216826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev at runtime. This identifier should be generated by a component in a way 217826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev that guarantees that every instance of the identifier running on the system 218826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev is unique. */ 219826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef unsigned char OMX_UUIDTYPE[128]; 220826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 221826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_DIRTYPE enumeration is used to indicate if a port is an input or 222826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev an output port. This enumeration is common across all component types. 223826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 224826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef enum OMX_DIRTYPE 225826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 226826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_DirInput, /**< Port is an input port */ 227826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_DirOutput, /**< Port is an output port */ 228826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_DirMax = 0x7FFFFFFF 229826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_DIRTYPE; 230826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 231826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_ENDIANTYPE enumeration is used to indicate the bit ordering 232826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev for numerical data (i.e. big endian, or little endian). 233826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 234826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef enum OMX_ENDIANTYPE 235826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 236826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_EndianBig, /**< big endian */ 237826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_EndianLittle, /**< little endian */ 238826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_EndianMax = 0x7FFFFFFF 239826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_ENDIANTYPE; 240826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 241826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 242826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_NUMERICALDATATYPE enumeration is used to indicate if data 243826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev is signed or unsigned 244826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 245826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef enum OMX_NUMERICALDATATYPE 246826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 247826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_NumericalDataSigned, /**< signed data */ 248826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_NumericalDataUnsigned, /**< unsigned data */ 249826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_NumercialDataMax = 0x7FFFFFFF 250826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_NUMERICALDATATYPE; 251826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 252826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 253826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** Unsigned bounded value type */ 254826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef struct OMX_BU32 { 255826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nValue; /**< actual value */ 256826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nMin; /**< minimum for value (i.e. nValue >= nMin) */ 257826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nMax; /**< maximum for value (i.e. nValue <= nMax) */ 258826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_BU32; 259826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 260826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 261826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** Signed bounded value type */ 262826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef struct OMX_BS32 { 263826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_S32 nValue; /**< actual value */ 264826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_S32 nMin; /**< minimum for value (i.e. nValue >= nMin) */ 265826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_S32 nMax; /**< maximum for value (i.e. nValue <= nMax) */ 266826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_BS32; 267826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 268826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 269826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** Structure representing some time or duration in microseconds. This structure 270826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * must be interpreted as a signed 64 bit value. The quantity is signed to accommodate 271826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * negative deltas and preroll scenarios. The quantity is represented in microseconds 272826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * to accomodate high resolution timestamps (e.g. DVD presentation timestamps based 273826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * on a 90kHz clock) and to allow more accurate and synchronized delivery (e.g. 2746eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * individual audio samples delivered at 192 kHz). The quantity is 64 bit to 275826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * accommodate a large dynamic range (signed 32 bit values would allow only for plus 276826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * or minus 35 minutes). 277826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * 278826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * Implementations with limited precision may convert the signed 64 bit value to 279826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * a signed 32 bit value internally but risk loss of precision. 280826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 281826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifndef OMX_SKIP64BIT 282826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef OMX_S64 OMX_TICKS; 283826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#else 284826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef struct OMX_TICKS 285826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 286826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nLowPart; /** low bits of the signed 64 bit tick value */ 287826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nHighPart; /** high bits of the signed 64 bit tick value */ 288826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_TICKS; 289826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 290826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#define OMX_TICKS_PER_SECOND 1000000 291826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 292826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** Define the public interface for the OMX Handle. The core will not use 293826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev this value internally, but the application should only use this value. 294826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 295826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef void* OMX_HANDLETYPE; 296826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 297826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef struct OMX_MARKTYPE 298826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 299826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_HANDLETYPE hMarkTargetComponent; /**< The component that will 300826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev generate a mark event upon 301826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev processing the mark. */ 3026eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal OMX_PTR pMarkData; /**< Application specific data associated with 303826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev the mark sent on a mark event to disambiguate 304826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev this mark from others. */ 305826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_MARKTYPE; 306826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 307826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 308826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_NATIVE_DEVICETYPE is used to map a OMX video port to the 3096eec4d1ea65df853450a6e158718981cba900bf6Shashank Mittal * platform & operating specific object used to reference the display 310826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * or can be used by a audio port for native audio rendering */ 311826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef void* OMX_NATIVE_DEVICETYPE; 312826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 313826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** OMX_NATIVE_WINDOWTYPE is used to map a OMX video port to the 314826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev * platform & operating specific object used to reference the window */ 315826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef void* OMX_NATIVE_WINDOWTYPE; 316826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 317826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/** The OMX_VERSIONTYPE union is used to specify the version for 318826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev a structure or component. For a component, the version is entirely 319826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev specified by the component vendor. Components doing the same function 320826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev from different vendors may or may not have the same version. For 321826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev structures, the version shall be set by the entity that allocates the 322826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev structure. For structures specified in the OMX 1.1 specification, the 323826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev value of the version shall be set to 1.1.0.0 in all cases. Access to the 324826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_VERSIONTYPE can be by a single 32 bit access (e.g. by nVersion) or 325826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev by accessing one of the structure elements to, for example, check only 326826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev the Major revision. 327826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev */ 328826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchevtypedef union OMX_VERSIONTYPE 329826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev{ 330826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev struct 331826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev { 332826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U8 nVersionMajor; /**< Major version accessor element */ 333826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U8 nVersionMinor; /**< Minor version accessor element */ 334826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U8 nRevision; /**< Revision version accessor element */ 335826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U8 nStep; /**< Step version accessor element */ 336826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev } s; 337826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev OMX_U32 nVersion; /**< 32 bit value to make accessing the 338826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev version easily done in a single word 339826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev size copy/compare operation */ 340826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} OMX_VERSIONTYPE; 341826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 342826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#ifdef __cplusplus 343826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev} 344826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif /* __cplusplus */ 345826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev 346826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev#endif 347826ececcbea342f7a0b92ec61847f1c95d384e05Iliyan Malchev/* File EOF */ 348