diff options
author | Ganesh Ajjanagadde <gajjanagadde@gmail.com> | 2015-10-29 00:12:53 -0400 |
---|---|---|
committer | Ganesh Ajjanagadde <gajjanagadde@gmail.com> | 2015-12-01 19:31:58 -0500 |
commit | 8c2438053786f10c5dc282dddd103b7a53570b47 (patch) | |
tree | 0a64d6899f9cbbe2ef707a340ce040830426673a | |
parent | 648b26acc5e25ab40c43fddc54b50e9f0b13ebd8 (diff) | |
download | ffmpeg-8c2438053786f10c5dc282dddd103b7a53570b47.tar.gz |
avfilter/af_volumedetect: use log10 instead of hardcoded constant
This is likely more precise and conveys the intent better.
Reviewed-by: Mark Harris <mark.hsj@gmail.com>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
-rw-r--r-- | libavfilter/af_volumedetect.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/af_volumedetect.c b/libavfilter/af_volumedetect.c index 01f24baea0..4815bccf6b 100644 --- a/libavfilter/af_volumedetect.c +++ b/libavfilter/af_volumedetect.c @@ -78,7 +78,7 @@ static inline double logdb(uint64_t v) double d = v / (double)(0x8000 * 0x8000); if (!v) return MAX_DB; - return log(d) * -4.3429448190325182765112891891660508229; /* -10/log(10) */ + return -log10(d) * 10; } static void print_stats(AVFilterContext *ctx) |