No HW surfaces in windowed modes?

I’m fairly new to SDL and I’ve noticed just now that no matter
what I do windowed modes always return SDL_SWSURFACEs. SDL_VideoInfo
reports i have support for it and it works fine in fullscreen modes.
Baffled I did some searching in the mailing list archives…

Currently all versions of SDL (with the possible
exception of SDL on Amiga) do not support hardware
surfaces in a window. Basically the problem is that
there is no way to prevent the SDL program to draw on
top of windows that might be on top of the SDL window
if the program has access to a hardware surface.

... Is this still correct?  If so it seems like a pretty

important issue that should be mentioned in the documentation.

Tom

Tom Spilman wrote:

Currently all versions of SDL (with the possible
exception of SDL on Amiga) do not support hardware
surfaces in a window. Basically the problem is that
there is no way to prevent the SDL program to draw on
top of windows that might be on top of the SDL window
if the program has access to a hardware surface.

… Is this still correct? If so it seems like a pretty
important issue that should be mentioned in the documentation.

AFAIK, yes.
But I don’t see why you make such big deal of it?–
Milan Babuskov
http://njam.sourceforge.net

AFAIK, yes.
But I don’t see why you make such big deal of it?

I'm doing a casual puzzle game which typically run in windowed

mode and i get 30fps vs. 10fps on a P2 266 when hardware blts are used.
Not all graphical applications run fullscreen. Once the documentation
site is working again I’ll be sure to add a little note about it.

Delving into the SDL source I found this interesting little

chunk of code in DX5_SetVideoMode…

#if 0 /* FIXME: enable this when SDL consistently reports lost surfaces
*/
if ( (flags & SDL_HWSURFACE) == SDL_HWSURFACE ) {
video->flags |= SDL_HWSURFACE;
} else {
video->flags |= SDL_SWSURFACE;
}
#else
video->flags |= SDL_SWSURFACE;
#endif

... which seems to be the culprit.  Any other details available

on this lost surfaces issue?

Tom> -----Original Message-----

From: sdl-admin at libsdl.org [mailto:sdl-admin at libsdl.org] On
Behalf Of Milan Babuskov
Sent: Tuesday, December 02, 2003 9:15 AM
To: sdl at libsdl.org
Subject: Re: [SDL] No HW surfaces in windowed modes?

Tom Spilman wrote:

Currently all versions of SDL (with the possible
exception of SDL on Amiga) do not support hardware
surfaces in a window. Basically the problem is that
there is no way to prevent the SDL program to draw on
top of windows that might be on top of the SDL window
if the program has access to a hardware surface.

... Is this still correct?  If so it seems like a 

pretty important

issue that should be mentioned in the documentation.

AFAIK, yes.
But I don’t see why you make such big deal of it?


Milan Babuskov
http://njam.sourceforge.net


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl