Greatly improved X11 DGA video speed (thanks Cezary!)
authorSam Lantinga <slouken@libsdl.org>
Sat, 09 Nov 2002 06:20:46 +0000
changeset 5404bcfb93e0dfe
parent 539 a9e38f3b8e4d
child 541 796f2fe699be
Greatly improved X11 DGA video speed (thanks Cezary!)
docs.html
src/video/dga/SDL_dgavideo.c
     1.1 --- a/docs.html	Sat Nov 09 06:13:28 2002 +0000
     1.2 +++ b/docs.html	Sat Nov 09 06:20:46 2002 +0000
     1.3 @@ -20,6 +20,7 @@
     1.4  Major changes since SDL 1.0.0:
     1.5  </H2>
     1.6  <UL>
     1.7 +	<LI> 1.2.6: Greatly improved X11 DGA video speed (thanks Cezary!)
     1.8  	<LI> 1.2.6: Added MMX audio mixing code for gcc (thanks Stephane!)
     1.9  	<LI> 1.2.6: Fixed potential dropped events under DirectInput
    1.10  	<LI> 1.2.6: Added Visual C++ 7 (.NET) projects (thanks James!)
     2.1 --- a/src/video/dga/SDL_dgavideo.c	Sat Nov 09 06:13:28 2002 +0000
     2.2 +++ b/src/video/dga/SDL_dgavideo.c	Sat Nov 09 06:20:46 2002 +0000
     2.3 @@ -816,7 +816,9 @@
     2.4    printf("Hardware accelerated rectangle fill: %dx%d at %d,%d\n", w, h, x, y);
     2.5  #endif
     2.6  	SDL_NAME(XDGAFillRectangle)(DGA_Display, DGA_Screen, x, y, w, h, color);
     2.7 -	XFlush(DGA_Display);
     2.8 +	if ( !(this->screen->flags & SDL_DOUBLEBUF) ) {
     2.9 +		XFlush(DGA_Display);
    2.10 +	}
    2.11  	DGA_AddBusySurface(dst);
    2.12  	UNLOCK_DISPLAY();
    2.13  	return(0);
    2.14 @@ -856,7 +858,9 @@
    2.15  		SDL_NAME(XDGACopyArea)(DGA_Display, DGA_Screen,
    2.16  			srcx, srcy, w, h, dstx, dsty);
    2.17  	}
    2.18 -	XFlush(DGA_Display);
    2.19 +	if ( !(this->screen->flags & SDL_DOUBLEBUF) ) {
    2.20 +		XFlush(DGA_Display);
    2.21 +	}
    2.22  	DGA_AddBusySurface(src);
    2.23  	DGA_AddBusySurface(dst);
    2.24  	UNLOCK_DISPLAY();