Commit 6c442e15 authored by Moritz Barsnick's avatar Moritz Barsnick Committed by Michael Niedermayer

lavc/libmp3lame: add support for cutoff

Pass the cutoff option from lavc's avcodec_options[] to libmp3lame's
lowpass option, without allowing to adjust its default behavior.
Signed-off-by: 's avatarMoritz Barsnick <barsnick@gmx.net>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 1bfb4587
......@@ -817,6 +817,10 @@ Set algorithm quality. Valid arguments are integers in the 0-9 range,
with 0 meaning highest quality but slowest, and 9 meaning fastest
while producing the worst quality.
@item cutoff (@emph{--lowpass})
Set lowpass cutoff frequency. If unspecified, the encoder dynamically
adjusts the cutoff.
@item reservoir
Enable use of bit reservoir when set to 1. Default value is 1. LAME
has this enabled by default, but can be overridden by use
......
......@@ -125,6 +125,10 @@ static av_cold int mp3lame_encode_init(AVCodecContext *avctx)
}
}
/* lowpass cutoff frequency */
if (avctx->cutoff)
lame_set_lowpassfreq(s->gfp, avctx->cutoff);
/* do not get a Xing VBR header frame from LAME */
lame_set_bWriteVbrTag(s->gfp,0);
......
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