Commit 8ffe1cb4 authored by Rostislav Pehlivanov's avatar Rostislav Pehlivanov

aacenc: disable bandtype modifying extensions when coder != twoloop

If the selected coder isn't twoloop, this commit temporarily
disables IS and PNS.
The problem is in the encode_window_bands_info() being confused
and setting invalid band_types for non-marked (normal) bands.
Signed-off-by: 's avatarRostislav Pehlivanov <atomnuker@gmail.com>
parent c3cd1a74
...@@ -797,6 +797,11 @@ static av_cold int aac_encode_init(AVCodecContext *avctx) ...@@ -797,6 +797,11 @@ static av_cold int aac_encode_init(AVCodecContext *avctx)
ERROR_IF(1, "Unsupported profile %d\n", avctx->profile); ERROR_IF(1, "Unsupported profile %d\n", avctx->profile);
} }
if (s->options.aac_coder != AAC_CODER_TWOLOOP) {
s->options.intensity_stereo = 0;
s->options.pns = 0;
}
avctx->bit_rate = (int)FFMIN( avctx->bit_rate = (int)FFMIN(
6144 * s->channels / 1024.0 * avctx->sample_rate, 6144 * s->channels / 1024.0 * avctx->sample_rate,
avctx->bit_rate); avctx->bit_rate);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment