Home | History | Annotate | Download | only in inc
      1 /*--------------------------------------------------------------------------
      2 Copyright (c) 2011 The Linux Foundation. All rights reserved.
      3 
      4 Redistribution and use in source and binary forms, with or without
      5 modification, are permitted provided that the following conditions are met:
      6     * Redistributions of source code must retain the above copyright
      7       notice, this list of conditions and the following disclaimer.
      8     * Redistributions in binary form must reproduce the above copyright
      9       notice, this list of conditions and the following disclaimer in the
     10       documentation and/or other materials provided with the distribution.
     11     * Neither the name of The Linux Foundation nor
     12       the names of its contributors may be used to endorse or promote
     13       products derived from this software without specific prior written
     14       permission.
     15 
     16 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
     17 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
     18 IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
     19 NON-INFRINGEMENT ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR
     20 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
     21 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
     22 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
     23 OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
     24 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
     25 OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
     26 ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     27 --------------------------------------------------------------------------*/
     28 
     29 #ifndef __QOMX_FILE_FORMAT_EXTENSIONS_H__
     30 #define __QOMX_FILE_FORMAT_EXTENSIONS_H__
     31 
     32 /*============================================================================
     33 *//** @file QOMX_FileFormatExtensions.h
     34   This header contains constants and type definitions that specify the
     35   extensions added to the OpenMAX Vendor specific APIs.
     36 *//*========================================================================*/
     37 
     38 /*============================================================================
     39                               Edit History
     40 
     41 when       who     what, where, why
     42 --------   ---     -------------------------------------------------------
     43 
     44 ============================================================================*/
     45 
     46 //////////////////////////////////////////////////////////////////////////////
     47 //                             Include Files
     48 //////////////////////////////////////////////////////////////////////////////
     49 #include "OMX_Core.h"
     50 
     51 
     52 /* :OMX.QCOM.index.param.container.info*/
     53 #define QOMX_QcomIndexParamContainerInfo 0x7F000009
     54 
     55 /**<OMX.Qualcomm.index.video.param.encrypttypeconfigparameters*/
     56 #define QOMX_FilemuxIndexEncryptionTypeConfigParameters 0x7F00000A
     57 
     58 #define QOMX_INDEX_CONTAINER_INFO_STRING    "QOMX.Qualcomm.index.param.containerinfo"
     59 #define OMX_QCOM_INDEX_FILE_FORMAT          "OMX.QCOM.index.config.FileFormat"
     60 #define QOMX_INDEX_CONFIG_ENCRYPT_TYPE      "QOMX.Qualcomm.index.config.EncryptType"
     61 
     62 /**-----------------------------------------------------------------------------
     63             OMX.QCOM.index.param.container.info
     64 --------------------------------------------------------------------------------
     65 */
     66 
     67 typedef enum QOMX_CONTAINER_FORMATTYPE {
     68     QOMX_FORMAT_RAW,
     69     QOMX_FORMAT_MP4,
     70     QOMX_FORMAT_3GP,
     71     QOMX_FORMAT_3G2,
     72     QOMX_FORMAT_AMC,
     73     QOMX_FORMAT_SKM,
     74     QOMX_FORMAT_K3G,
     75     QOMX_FORMAT_VOB,
     76     QOMX_FORMAT_AVI,
     77     QOMX_FORMAT_ASF,
     78     QOMX_FORMAT_RM ,
     79     QOMX_FORMAT_MPEG_ES,
     80     QOMX_FORMAT_DIVX,
     81     QOMX_FORMATMPEG_TS,
     82     QOMX_FORMAT_QT,
     83     QOMX_FORMAT_M4A,
     84     QOMX_FORMAT_MP3,
     85     QOMX_FORMAT_WAVE,
     86     QOMX_FORMAT_XMF,
     87     QOMX_FORMAT_AMR,
     88     QOMX_FORMAT_AAC,
     89     QOMX_FORMAT_EVRC,
     90     QOMX_FORMAT_QCP,
     91     QOMX_FORMAT_SMF,
     92     QOMX_FORMAT_OGG,
     93     QOMX_FORMAT_BMP,
     94     QOMX_FORMAT_JPG,
     95     QOMX_FORMAT_JPG2000
     96 }QOMX_CONTAINER_FORMATTYPE;
     97 
     98 typedef struct QOMX_CONTAINER_INFOTYPE {
     99     OMX_U32 nSize;
    100     OMX_VERSIONTYPE nVersion;
    101     QOMX_CONTAINER_FORMATTYPE eFmtType;
    102 } QOMX_CONTAINER_INFOTYPE;
    103 
    104 typedef enum QOMX_FILEFORMATTYPE {
    105     QOMX_FileFormatNone, /**< no file format naming convention is followed. */
    106     QOMX_FileFormatDCF, /**< DCF file naming convention. */
    107     QOMX_FileFormatMax = 0x7FFFFFFF
    108 } QOMX_FILEFORMATTYPE;
    109 
    110 /** QOMX_CONFIG_FILEFORMATTYPE is used to determine how the file writer will interpret
    111 the provided content URI and whether it will increment the index of the file name. */
    112 typedef struct QOMX_CONFIG_FILEFORMATTYPE {
    113     OMX_U32 nSize; /**< size of the structure in bytes */
    114     OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
    115     OMX_U32 nPortIndex; /**< port that this structure applies to */
    116     QOMX_FILEFORMATTYPE eFileFormat; /** file format type */
    117 } QOMX_CONFIG_FILEFORMATTYPE;
    118 
    119 /**The QOMX_RECORDINGSTATISTICSINTERVALTYPE structure is used to enable
    120 IL client to indicate the interval of the statistics notification to file mux
    121 component. Time interval will indicate the frequency(in ms) when client needs
    122 the statistics data*/
    123 typedef struct QOMX_RECORDINGSTATISTICSINTERVALTYPE {
    124     OMX_U32 nSize; /**< size of the structure in bytes */
    125     OMX_VERSIONTYPE nVersion;/**< OMX specification version information */
    126     OMX_TICKS  interval;/**< specifies the time(milliseconds) between updates */
    127    }QOMX_RECORDINGSTATISTICSINTERVALTYPE;
    128 
    129 /**QOMX_RECORDINGSTATISTICSTYPE indicates the current recording
    130 time and space statistics of this session, which can be used by client to
    131 identify current status of recorded data in milliseconds and bytes */
    132 typedef struct QOMX_RECORDINGSTATISTICSTYPE {
    133     OMX_U32 nSize;/**< size of the structure in bytes */
    134     OMX_VERSIONTYPE nVersion;/**< OMX specification version information */
    135     OMX_TICKS  nRecordedTime; /**  duration that we already recorded*/
    136     OMX_TICKS  nTimeCanRecord;/** the time we can record at the same bitrate*/
    137     OMX_U64   nSpaceConsumed;/** space that consumed in bytes*/
    138     OMX_U64  nSpaceLeft;/** space left in bytes*/
    139 } QOMX_RECORDINGSTATISTICSTYPE;
    140 
    141 /**QOMX_ENCRYPT_TYPE indicates the type of encryption */
    142 typedef enum QOMX_ENCRYPT_TYPE {
    143     QOMX_ENCRYPT_TYPE_HDCP,
    144     QOMX_ENCRYPT_TYPE_INVALID
    145 }QOMX_ENCRYPT_TYPE;
    146 
    147 /**QOMX_ENCRYPTIONTYPE indicates the encrypt type */
    148 typedef struct QOMX_ENCRYPTIONTYPE {
    149     OMX_U32            nSize;  /**< size of the structure in bytes */
    150     OMX_VERSIONTYPE    nVersion; /**< OMX specification version information */
    151     OMX_BOOL           nStreamEncrypted;  /** stream is encrypted or not */
    152     QOMX_ENCRYPT_TYPE  nType;  /** type of Encryption */
    153     OMX_U32            nEncryptVersion; /** Encrypt version */
    154 } QOMX_ENCRYPTIONTYPE;
    155 #endif /*__QOMX_FILE_FORMAT_EXTENSIONS_H__*/
    156