From 542f783b189fe7d2139a1e5e8c37f5b0f264805b Mon Sep 17 00:00:00 2001 From: Richard Wilson Date: Wed, 10 Nov 2004 19:51:32 +0000 Subject: [project @ 2004-11-10 19:51:31 by rjw] Further GIF optimisation to reduce flicker. svn path=/import/netsurf/; revision=1356 --- image/gif.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'image/gif.c') diff --git a/image/gif.c b/image/gif.c index 697ef408f..8fabf5033 100644 --- a/image/gif.c +++ b/image/gif.c @@ -220,7 +220,12 @@ void nsgif_animate(void *p) data.redraw.full_redraw = c->data.gif.gif->frames[c->data.gif.current_frame - 1].redraw_required; } else { - data.redraw.full_redraw = true; + /* do advanced check */ + data.redraw.full_redraw = !((c->data.gif.current_frame == 0) && + (bitmap_get_opaque(c->data.gif.gif->frame_image)) && + (data.redraw.x == 0) && (data.redraw.y == 0) && + (data.redraw.width = c->data.gif.gif->width) && + (data.redraw.height = c->data.gif.gif->height)); } /* other data */ -- cgit v1.2.3