1c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu/*
2c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * Copyright (c) 2010 The Khronos Group Inc.
3c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu *
4c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * Permission is hereby granted, free of charge, to any person obtaining
5c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * a copy of this software and associated documentation files (the
6c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * "Software"), to deal in the Software without restriction, including
7c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * without limitation the rights to use, copy, modify, merge, publish,
8c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * distribute, sublicense, and/or sell copies of the Software, and to
9c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * permit persons to whom the Software is furnished to do so, subject
10c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * to the following conditions:
11c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * The above copyright notice and this permission notice shall be included
12c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * in all copies or substantial portions of the Software.
13c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu *
14c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
15c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
18c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
19c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
20c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu *
22c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu */
23c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
24c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu/** OMX_AudioExt.h - OpenMax IL version 1.1.2
25c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * The OMX_AudioExt header file contains extensions to the
26c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * definitions used by both the application and the component to
27c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * access video items.
28c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu */
29c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
30c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#ifndef OMX_AudioExt_h
31c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#define OMX_AudioExt_h
32c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
33c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#ifdef __cplusplus
34c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryuextern "C" {
35c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#endif /* __cplusplus */
36c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
37c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu/* Each OMX header shall include all required header files to allow the
38c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * header to compile without errors.  The includes below are required
39c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu * for this header file to compile successfully
40c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu */
41c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#include <OMX_Core.h>
42c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
43e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi#define OMX_AUDIO_AACToolAndroidSSBR (OMX_AUDIO_AACToolVendor << 0) /**< SSBR: MPEG-4 Single-rate (downsampled) Spectral Band Replication tool allowed or active */
44e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi#define OMX_AUDIO_AACToolAndroidDSBR (OMX_AUDIO_AACToolVendor << 1) /**< DSBR: MPEG-4 Dual-rate Spectral Band Replication tool allowed or active */
45e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi
46c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryutypedef enum OMX_AUDIO_CODINGEXTTYPE {
47c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_AUDIO_CodingAndroidUnused = OMX_AUDIO_CodingKhronosExtensions + 0x00100000,
48c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_AUDIO_CodingAndroidAC3,         /**< AC3 encoded data */
491a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_AUDIO_CodingAndroidOPUS,        /**< OPUS encoded data */
50806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_AUDIO_CodingAndroidEAC3,        /**< EAC3 encoded data */
51c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu} OMX_AUDIO_CODINGEXTTYPE;
52c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
53c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryutypedef struct OMX_AUDIO_PARAM_ANDROID_AC3TYPE {
54c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_U32 nSize;                 /**< size of the structure in bytes */
55c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_VERSIONTYPE nVersion;      /**< OMX specification version information */
56c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_U32 nPortIndex;            /**< port that this structure applies to */
57c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_U32 nChannels;             /**< Number of channels */
58c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu    OMX_U32 nSampleRate;           /**< Sampling rate of the source data.  Use 0 for
59c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu                                        variable or unknown sampling rate. */
60c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu} OMX_AUDIO_PARAM_ANDROID_AC3TYPE;
61c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
62806f23de71be2494cfabbe08d11c09606966a5d5Rachadtypedef struct OMX_AUDIO_PARAM_ANDROID_EAC3TYPE {
63806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_U32 nSize;                 /**< size of the structure in bytes */
64806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_VERSIONTYPE nVersion;      /**< OMX specification version information */
65806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_U32 nPortIndex;            /**< port that this structure applies to */
66806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_U32 nChannels;             /**< Number of channels */
67806f23de71be2494cfabbe08d11c09606966a5d5Rachad    OMX_U32 nSampleRate;           /**< Sampling rate of the source data.  Use 0 for
68806f23de71be2494cfabbe08d11c09606966a5d5Rachad                                        variable or unknown sampling rate. */
69806f23de71be2494cfabbe08d11c09606966a5d5Rachad} OMX_AUDIO_PARAM_ANDROID_EAC3TYPE;
70806f23de71be2494cfabbe08d11c09606966a5d5Rachad
711a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramaniantypedef struct OMX_AUDIO_PARAM_ANDROID_OPUSTYPE {
721a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nSize;            /**< size of the structure in bytes */
731a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
741a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nPortIndex;       /**< port that this structure applies to */
751a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nChannels;        /**< Number of channels */
761a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nBitRate;         /**< Bit rate of the encoded data data.  Use 0 for variable
771a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian                                   rate or unknown bit rates. Encoding is set to the
781a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian                                   bitrate closest to specified  value (in bps) */
791a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nSampleRate;      /**< Sampling rate of the source data.  Use 0 for
801a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian                                   variable or unknown sampling rate. */
811a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian    OMX_U32 nAudioBandWidth;  /**< Audio band width (in Hz) to which an encoder should
821a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian                                   limit the audio signal. Use 0 to let encoder decide */
831a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian} OMX_AUDIO_PARAM_ANDROID_OPUSTYPE;
841a8b0ed985b3767fdd795fb5216014e05b30791bVignesh Venkatasubramanian
85e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivitypedef struct OMX_AUDIO_PARAM_ANDROID_AACPRESENTATIONTYPE {
86e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_U32 nSize;            /**< size of the structure in bytes */
87e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
88e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nMaxOutputChannels;    /**< Maximum channel count to be output, -1 if unspecified, 0 if downmixing disabled */
89e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nDrcCut;               /**< The DRC attenuation factor, between 0 and 127, -1 if unspecified */
90e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nDrcBoost;             /**< The DRC amplification factor, between 0 and 127, -1 if unspecified */
91e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nHeavyCompression;     /**< 0 for light compression, 1 for heavy compression, -1 if unspecified */
92e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nTargetReferenceLevel; /**< Target reference level, between 0 and 127, -1 if unspecified */
93e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi    OMX_S32 nEncodedTargetLevel;   /**< Target reference level assumed at the encoder, between 0 and 127, -1 if unspecified */
94db8cad15857007165ad8045c610ff2591759560aChong Zhang    OMX_S32 nPCMLimiterEnable;     /**< Signal level limiting, 0 for disable, 1 for enable, -1 if unspecified */
95e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi} OMX_AUDIO_PARAM_ANDROID_AACPRESENTATIONTYPE;
96e91cd213d439c076051b1fb02c8bc40c11791dbbJean-Michel Trivi
97c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#ifdef __cplusplus
98c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu}
99c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#endif /* __cplusplus */
100c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu
101c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu#endif /* OMX_AudioExt_h */
102c9a8a34e40b4e5ba76ace8879e479ebf5fbca3c5Changwan Ryu/* File EOF */
103