[FFmpeg-devel] [PATCH]Sanitize VBR setting for libfdk-aac
Carl Eugen Hoyos
cehoyos at ag.or.at
Tue Sep 11 09:12:11 CEST 2012
Hi!
It is currently slightly too difficult to set vbr when encoding with libfdk-
aac.
Please comment, Carl Eugen
-------------- next part --------------
diff --git a/libavcodec/libfdk-aacenc.c b/libavcodec/libfdk-aacenc.c
index 965ead6..2b74f67 100644
--- a/libavcodec/libfdk-aacenc.c
+++ b/libavcodec/libfdk-aacenc.c
@@ -174,7 +174,7 @@ static av_cold int aac_encode_init(AVCodecContext *avctx)
}
if (avctx->flags & CODEC_FLAG_QSCALE) {
- int mode = avctx->global_quality;
+ int mode = avctx->global_quality / FF_QP2LAMBDA;
if (mode < 1 || mode > 5) {
av_log(avctx, AV_LOG_WARNING,
"VBR quality %d out of range, should be 1-5\n", mode);
More information about the ffmpeg-devel
mailing list