Commit b8e19808 authored by Ganesh Ajjanagadde's avatar Ganesh Ajjanagadde

avfilter/vf_ssim: use log10 instead of log()/log(10)

This is likely more precise and conveys the intent better.
Reviewed-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
Signed-off-by: 's avatarGanesh Ajjanagadde <gajjanagadde@gmail.com>
parent ec66bcc0
......@@ -176,7 +176,7 @@ static float ssim_plane(SSIMDSPContext *dsp,
static double ssim_db(double ssim, double weight)
{
return 10 * (log(weight) / log(10) - log(weight - ssim) / log(10));
return 10 * log10(weight / (weight - ssim));
}
static AVFrame *do_ssim(AVFilterContext *ctx, AVFrame *main,
......
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