summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xconfigure4
-rw-r--r--doc/encoders.texi3
-rw-r--r--libavcodec/libfdk-aacenc.c6
3 files changed, 10 insertions, 3 deletions
diff --git a/configure b/configure
index c46bfd3c5c..32bc5baf87 100755
--- a/configure
+++ b/configure
@@ -4437,9 +4437,7 @@ enabled libcelt && require libcelt celt/celt.h celt_decode -lcelt0 &&
die "ERROR: libcelt must be installed and version must be >= 0.11.0."; }
enabled libcaca && require_pkg_config caca caca.h caca_create_canvas
enabled libfaac && require2 libfaac "stdint.h faac.h" faacEncGetVersion -lfaac
-enabled libfdk_aac && require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac &&
- { check_cpp_condition fdk-aac/aacenc_lib.h "AACENCODER_LIB_VL0 >= 3 && AACENCODER_LIB_VL1 >= 4 && AACENCODER_LIB_VL2 >= 12" ||
- die "ERROR: libfdk-aac must be installed and version must be >= 0.1.3."; }
+enabled libfdk_aac && require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac
flite_libs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
enabled libflite && require2 libflite "flite/flite.h" flite_init $flite_libs
enabled libfreetype && require_libfreetype
diff --git a/doc/encoders.texi b/doc/encoders.texi
index d163440da4..c28cbcbdf4 100644
--- a/doc/encoders.texi
+++ b/doc/encoders.texi
@@ -623,6 +623,9 @@ VBR encoding, enabled through the @option{vbr} or @option{flags
+qscale} options, is experimental and only works with some
combinations of parameters.
+Support for encoding 7.1 audio is only available with libfdk-aac 0.1.3 or
+higher.
+
For more information see the fdk-aac project at
@url{http://sourceforge.net/p/opencore-amr/fdk-aac/}.
diff --git a/libavcodec/libfdk-aacenc.c b/libavcodec/libfdk-aacenc.c
index 2d91e58558..bc70400898 100644
--- a/libavcodec/libfdk-aacenc.c
+++ b/libavcodec/libfdk-aacenc.c
@@ -151,6 +151,9 @@ static av_cold int aac_encode_init(AVCodecContext *avctx)
case 4: mode = MODE_1_2_1; sce = 2; cpe = 1; break;
case 5: mode = MODE_1_2_2; sce = 1; cpe = 2; break;
case 6: mode = MODE_1_2_2_1; sce = 2; cpe = 2; break;
+/* The version macro is introduced the same time as the 7.1 support, so this
+ should suffice. */
+#ifdef AACENCODER_LIB_VL0
case 8:
sce = 2;
cpe = 3;
@@ -161,6 +164,7 @@ static av_cold int aac_encode_init(AVCodecContext *avctx)
mode = MODE_7_1_FRONT_CENTER;
}
break;
+#endif
default:
av_log(avctx, AV_LOG_ERROR,
"Unsupported number of channels %d\n", avctx->channels);
@@ -394,8 +398,10 @@ static const uint64_t aac_channel_layout[] = {
AV_CH_LAYOUT_4POINT0,
AV_CH_LAYOUT_5POINT0_BACK,
AV_CH_LAYOUT_5POINT1_BACK,
+#ifdef AACENCODER_LIB_VL0
AV_CH_LAYOUT_7POINT1_WIDE_BACK,
AV_CH_LAYOUT_7POINT1,
+#endif
0,
};