media: add and clarify OMX float numerical type
Bug: 27172163
Change-Id: Idb399c05d14ee51f944251430d3561479feee6e3
diff --git a/include/media/openmax/OMX_Audio.h b/include/media/openmax/OMX_Audio.h
index a0cbd3b..d8bee76 100644
--- a/include/media/openmax/OMX_Audio.h
+++ b/include/media/openmax/OMX_Audio.h
@@ -178,7 +178,7 @@
OMX_VERSIONTYPE nVersion; /**< OMX specification version information */
OMX_U32 nPortIndex; /**< port that this structure applies to */
OMX_U32 nChannels; /**< Number of channels (e.g. 2 for stereo) */
- OMX_NUMERICALDATATYPE eNumData; /**< indicates PCM data as signed or unsigned */
+ OMX_NUMERICALDATATYPE eNumData; /**< indicates PCM data as signed, unsigned or floating pt. */
OMX_ENDIANTYPE eEndian; /**< indicates PCM data as little or big endian */
OMX_BOOL bInterleaved; /**< True for normal interleaved data; false for
non-interleaved data (e.g. block data) */
diff --git a/include/media/openmax/OMX_Types.h b/include/media/openmax/OMX_Types.h
index 5afaba0..515e002 100644
--- a/include/media/openmax/OMX_Types.h
+++ b/include/media/openmax/OMX_Types.h
@@ -280,12 +280,18 @@
/** The OMX_NUMERICALDATATYPE enumeration is used to indicate if data
- is signed or unsigned
+ is signed, unsigned or floating point (Android extension).
+
+ Android floating point support policy:
+ If component does not support floating point raw audio, it can reset
+ configuration to signed 16-bit integer (support for which is required.)
+ nBitsPerSample will be set to 32 for float data.
*/
typedef enum OMX_NUMERICALDATATYPE
{
OMX_NumericalDataSigned, /**< signed data */
OMX_NumericalDataUnsigned, /**< unsigned data */
+ OMX_NumericalDataFloat = 0x7F000001, /**< floating point data */
OMX_NumercialDataMax = 0x7FFFFFFF
} OMX_NUMERICALDATATYPE;