mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-04-08 16:54:03 +02:00
lavfi/af_volume: replace pow(10,x) by ff_exp10(x)
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
This commit is contained in:
parent
e0024b9e5f
commit
6c360ca8a1
@ -376,7 +376,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *buf)
|
|||||||
av_log(inlink->dst, AV_LOG_VERBOSE,
|
av_log(inlink->dst, AV_LOG_VERBOSE,
|
||||||
"Using gain %f dB from replaygain side data.\n", g);
|
"Using gain %f dB from replaygain side data.\n", g);
|
||||||
|
|
||||||
vol->volume = pow(10, (g + vol->replaygain_preamp) / 20);
|
vol->volume = ff_exp10((g + vol->replaygain_preamp) / 20);
|
||||||
if (vol->replaygain_noclip)
|
if (vol->replaygain_noclip)
|
||||||
vol->volume = FFMIN(vol->volume, 1.0 / p);
|
vol->volume = FFMIN(vol->volume, 1.0 / p);
|
||||||
vol->volume_i = (int)(vol->volume * 256 + 0.5);
|
vol->volume_i = (int)(vol->volume * 256 + 0.5);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user