[FFmpeg-cvslog] avfilter/avf_showvolume: use log10 instead of log()/M_LN10
Ganesh Ajjanagadde
git at videolan.org
Fri Oct 30 00:12:38 CET 2015
ffmpeg | branch: master | Ganesh Ajjanagadde <gajjanagadde at gmail.com> | Thu Oct 29 00:15:25 2015 -0400| [0fe5dcd66041183c2ada3847b968c425f104b0c5] | committer: Ganesh Ajjanagadde
avfilter/avf_showvolume: use log10 instead of log()/M_LN10
This is likely more precise and conveys the intent better.
Reviewed-by: Paul B Mahol <onemda at gmail.com>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0fe5dcd66041183c2ada3847b968c425f104b0c5
---
libavfilter/avf_showvolume.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavfilter/avf_showvolume.c b/libavfilter/avf_showvolume.c
index 95b5388..395375a 100644
--- a/libavfilter/avf_showvolume.c
+++ b/libavfilter/avf_showvolume.c
@@ -197,7 +197,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *insamples)
max = FFMAX(max, src[i]);
max = av_clipf(max, 0, 1);
- values[VAR_VOLUME] = 20.0 * log(max) / M_LN10;
+ values[VAR_VOLUME] = 20.0 * log10(max);
values[VAR_CHANNEL] = c;
color = av_expr_eval(s->c_expr, values, NULL);
More information about the ffmpeg-cvslog
mailing list