Commit 1a266a1e authored by Paul B Mahol's avatar Paul B Mahol

avfilter/af_anlmdn: try to recover when cache becomes negative

parent b5355774
......@@ -224,7 +224,10 @@ static int filter_channel(AVFilterContext *ctx, void *arg, int ch, int nb_jobs)
unsigned weight_lut_idx;
float w;
av_assert2(distance >= 0.f);
if (distance < 0.f) {
cache[j] = 0.f;
continue;
}
w = distance * sw;
if (w >= smooth)
continue;
......
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