From 0a451082c774540f8d47642d2078fcf2c822ebc1 Mon Sep 17 00:00:00 2001 From: Paul B Mahol Date: Sun, 3 Jan 2016 22:43:21 +0100 Subject: [PATCH] avfilter/avf_showspectrum: finally fix log scaler Signed-off-by: Paul B Mahol --- libavfilter/avf_showspectrum.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/avf_showspectrum.c b/libavfilter/avf_showspectrum.c index 6e73b9e55a..48d811e2c4 100644 --- a/libavfilter/avf_showspectrum.c +++ b/libavfilter/avf_showspectrum.c @@ -581,7 +581,7 @@ static int plot_spectrum_column(AVFilterLink *inlink, AVFrame *insamples) a = pow(a, 0.20); break; case LOG: - a = 1 + log10(FFMAX(FFMIN(1, a), 1e-6)) / 5; // zero = -120dBFS + a = 1 + log10(FFMAX(FFMIN(1, a * w), 1e-6)) / 6; // zero = -120dBFS break; default: av_assert0(0);