Changing from Full screen to Windows and back

[…] Is the performance gained, if any, using ony hardware
surfaces
(sprites, tiles, etc) worth the trouble to avoid such problems (or
worth
using hardware surfaces for that, anyway)? Because I tested using
only
software surfaces (changed the flags on initialization, duh :P)
and I had
no video problem on changing from my full screen app to Windows
and
coming back.

I did some performance tests a while back on my WinXP laptop, which
has an NVidia GeForce2 Go. Hardware-to-hardware blits were on
average 4 times faster than software-to-software blits, and over 9
times faster than blitting from software-to-hardware. If you use
software surfaces only, SDL will not sync to vertical blank, so
you’re also likely to experience tearing. Hardware page flipping
(HWSURFACE | DOUBLEBUF) is virtually free, but when your main
surface is a SWSURFACE, SDL has to blit the main software surface to
the screen at some point, which on my machine took up to 8ms (in
windowed mode). So yes, use hardware surfaces when you can :wink: Of
course, YMMV.–
Matthijs Hollemans
All Your Software
www.allyoursoftware.com

I did some performance tests a while back on my WinXP laptop, which
has an NVidia GeForce2 Go. Hardware-to-hardware blits were on
average 4 times faster than software-to-software blits, and over 9
times faster than blitting from software-to-hardware. If you use

     Hmm, great to know it. While the game I'm working right now won't 

need ALL that speed, I will improve the engine later so the performance
will be needed :).

software surfaces only, SDL will not sync to vertical blank, so
you’re also likely to experience tearing. Hardware page flipping

     I have already noticed it, and as there's no vsync, the scroll 

looks choppy.

(HWSURFACE | DOUBLEBUF) is virtually free, but when your main
surface is a SWSURFACE, SDL has to blit the main software surface to

     BTW, does anyone knows of video hardware that DOES NOT support 

hardware surface with double buffer on smaller resolutions, like 640x480
with 32 and 16 bpp?

the screen at some point, which on my machine took up to 8ms (in
windowed mode). So yes, use hardware surfaces when you can :wink: Of
course, YMMV.

     Well, I can and will most likely keep on using them :). It was 

just something that I thought and woulb be interesting to know BEFORE I got
further on my engine and it was too late (or too complicated) to change it ^_-.

     Paulo