[FFmpeg-cvslog] aacenc: treat unknown profile as AAC-LC

Rostislav Pehlivanov git at videolan.org
Fri Aug 21 22:31:12 CEST 2015


ffmpeg | branch: master | Rostislav Pehlivanov <atomnuker at gmail.com> | Fri Aug 21 21:28:20 2015 +0100| [88a5f93f629a6eca96c348c40902a541f10ef467] | committer: Rostislav Pehlivanov

aacenc: treat unknown profile as AAC-LC

When the encoder is ran without specifying -profile:a
the default avctx->profile value is -99 (FF_PROFILE_UKNOWN),
which used to be treated as AAC-LC.

Signed-off-by: Rostislav Pehlivanov <atomnuker at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=88a5f93f629a6eca96c348c40902a541f10ef467
---

 libavcodec/aacenc.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c
index 0ffa4a2..af77379 100644
--- a/libavcodec/aacenc.c
+++ b/libavcodec/aacenc.c
@@ -789,7 +789,8 @@ static av_cold int aac_encode_init(AVCodecContext *avctx)
     } else if (avctx->profile == FF_PROFILE_AAC_LOW && s->options.pred) {
         s->profile = 0; /* Main */
         WARN_IF(1, "Prediction requested, changing profile to AAC-Main\n");
-    } else if (avctx->profile == FF_PROFILE_AAC_LOW) {
+    } else if (avctx->profile == FF_PROFILE_AAC_LOW ||
+        avctx->profile == FF_PROFILE_UNKNOWN) {
         s->profile = 1; /* Low */
     } else {
         ERROR_IF(1, "Unsupported profile %d\n", avctx->profile);



More information about the ffmpeg-cvslog mailing list