diff options
Diffstat (limited to 'libAACenc')
-rw-r--r-- | libAACenc/include/aacenc_lib.h | 2 | ||||
-rw-r--r-- | libAACenc/src/aacenc.h | 5 | ||||
-rw-r--r-- | libAACenc/src/aacenc_lib.cpp | 2 | ||||
-rw-r--r-- | libAACenc/src/metadata_main.cpp | 15 |
4 files changed, 16 insertions, 8 deletions
diff --git a/libAACenc/include/aacenc_lib.h b/libAACenc/include/aacenc_lib.h index 4f8f223..902ba11 100644 --- a/libAACenc/include/aacenc_lib.h +++ b/libAACenc/include/aacenc_lib.h @@ -332,7 +332,7 @@ If the present library is configured with Metadata support, it is possible to insert meta data side info into the generated audio bitstream while encoding. To work with meta data the encoder instance has to be \ref encOpen "allocated" -with meta data support. The meta data mode must be be configured with the +with meta data support. The meta data mode must be configured with the ::AACENC_METADATA_MODE parameter and aacEncoder_SetParam() function. \code aacEncoder_SetParam(hAacEncoder, AACENC_METADATA_MODE, 0-3); \endcode diff --git a/libAACenc/src/aacenc.h b/libAACenc/src/aacenc.h index b7e0ef2..2d95abb 100644 --- a/libAACenc/src/aacenc.h +++ b/libAACenc/src/aacenc.h @@ -206,8 +206,9 @@ typedef enum { CH_ORDER_MPEG = 0, /*!< MPEG channel ordering (e. g. 5.1: C, L, R, SL, SR, LFE) */ - CH_ORDER_WAV /*!< WAV fileformat channel ordering (e. g. 5.1: L, R, C, LFE, - SL, SR) */ + CH_ORDER_WAV, /*!< WAV fileformat channel ordering (e. g. 5.1: L, R, C, LFE, + SL, SR) */ + CH_ORDER_WG4 /*!< WG4 fileformat channel ordering (e. g. 5.1: L, R, SL, SR, C, LFE) */ } CHANNEL_ORDER; diff --git a/libAACenc/src/aacenc_lib.cpp b/libAACenc/src/aacenc_lib.cpp index c11db27..ee7f918 100644 --- a/libAACenc/src/aacenc_lib.cpp +++ b/libAACenc/src/aacenc_lib.cpp @@ -2234,7 +2234,7 @@ AACENC_ERROR aacEncoder_SetParam(const HANDLE_AACENCODER hAacEncoder, break; case AACENC_CHANNELORDER: if (hAacEncoder->aacConfig.channelOrder != (CHANNEL_ORDER)value) { - if (!((value == 0) || (value == 1))) { + if (!((value == 0) || (value == 1) || (value == 2))) { err = AACENC_INVALID_CONFIG; break; } diff --git a/libAACenc/src/metadata_main.cpp b/libAACenc/src/metadata_main.cpp index edd3831..ada4502 100644 --- a/libAACenc/src/metadata_main.cpp +++ b/libAACenc/src/metadata_main.cpp @@ -491,10 +491,17 @@ FDK_METADATA_ERROR FDK_MetadataEnc_Init( FDK_channelMapDescr mapDescrPrev, mapDescr; int c, src[2] = {-1, -1}, dst[2] = {-1, -1}; - FDK_chMapDescr_init(&mapDescrPrev, NULL, 0, - (channelOrder == CH_ORDER_MPEG) ? 1 : 0); - FDK_chMapDescr_init(&mapDescr, NULL, 0, - (channelOrder == CH_ORDER_MPEG) ? 1 : 0); + if (channelOrder == CH_ORDER_WG4) { + FDK_chMapDescr_init(&mapDescrPrev, FDK_mapInfoTabWg4, + FDK_mapInfoTabLenWg4, 0); + FDK_chMapDescr_init(&mapDescr, FDK_mapInfoTabWg4, + FDK_mapInfoTabLenWg4, 0); + } else { + FDK_chMapDescr_init(&mapDescrPrev, NULL, 0, + (channelOrder == CH_ORDER_MPEG) ? 1 : 0); + FDK_chMapDescr_init(&mapDescr, NULL, 0, + (channelOrder == CH_ORDER_MPEG) ? 1 : 0); + } switch (channelMode) { case MODE_1: |