From c6cbbd292aa59c4b88abcff85bd327606cf821de Mon Sep 17 00:00:00 2001 From: Rudolf Polzer Date: Sun, 16 Jun 2013 17:22:37 +0200 Subject: vf_dlopen ildetect: fix numdecidedadjacentframes counter --- TOOLS/vf_dlopen/ildetect.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'TOOLS') diff --git a/TOOLS/vf_dlopen/ildetect.c b/TOOLS/vf_dlopen/ildetect.c index 6aa62a1153..1ac1c08946 100644 --- a/TOOLS/vf_dlopen/ildetect.c +++ b/TOOLS/vf_dlopen/ildetect.c @@ -184,13 +184,17 @@ static int il_put_image(struct vf_dlopen_context *ctx) double avgcombed = totalcombedframes / (double) totalpixels; if (il->lastcombed >= 0) { + if (il->lastcombed < il->no_threshold || + il->lastcombed > il->yes_threshold) + if (avgcombed < il->no_threshold || + avgcombed > il->yes_threshold) + ++il->numdecidedadjacentframes; if (il->lastcombed > il->yes_threshold && avgcombed < il->no_threshold) ++il->numjumpingadjacentframes; if (il->lastcombed < il->no_threshold && avgcombed > il->yes_threshold) ++il->numjumpingadjacentframes; - ++il->numdecidedadjacentframes; } il->lastcombed = avgcombed; -- cgit v1.2.3