Commit ed3b6440 authored by Paul B Mahol's avatar Paul B Mahol

avfilter/af_anlmdn: ignore too small values

parent 8a1fc958
...@@ -168,7 +168,10 @@ static int filter_channel(AVFilterContext *ctx, void *arg, int ch, int nb_jobs) ...@@ -168,7 +168,10 @@ static int filter_channel(AVFilterContext *ctx, void *arg, int ch, int nb_jobs)
float w; float w;
av_assert0(distance >= 0.f); av_assert0(distance >= 0.f);
w = expf(-distance * sw); w = -distance * sw;
if (w < -11.f)
continue;
w = expf(w);
P += w * f[i - S + j + (j >= S)]; P += w * f[i - S + j + (j >= S)];
Q += w; Q += w;
} }
......
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