Re: [AD] vsync and SVGAlib (was Problems: Grabber and windowing)

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> The problem is that everything seems to work fine on my system: the demo
> doesn't  flicker at all when using page flipping with SVGAlib. So I want
> to further investigate, including to look into the SVGAlib sources.

I lied. The demo badly flickers too on my system. I've commited the following 
patch, which implements the method used in the scrolltest.c demo program of 
SVGAlib 1.4.3 and does fix the flicker. Yeah!

Index: src/linux/svgalib.c
===================================================================
RCS file: /cvsroot/alleg/allegro/src/linux/svgalib.c,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -p -r1.29 -r1.30
--- src/linux/svgalib.c 15 Jan 2002 00:44:05 -0000      1.29
+++ src/linux/svgalib.c 20 Jan 2003 23:16:05 -0000      1.30
@@ -508,6 +508,10 @@ static int svga_scroll(int x, int y)
    vga_setdisplaystart((x + y * bytes_per_line) /* & display_start_mask */);
    /* The bitmask seems to mess things up on my machine, even though
     * the documentation says it should be there. -- PW  */
+
+   /* wait for a retrace */
+   vga_waitretrace();
+
    return 0;
 }

-- 
Eric Botcazou




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/