[SDL] Overlay surfaces [vs SDL 1.2.7]
Sam Lantinga
slouken at devolution.com
Thu Feb 26 12:44:41 PST 2004
> But besides all this, I was essentially happy, having restricted my
> application to only considering overlay surfaces if in full screen mode.
> This was under SDL 1.2.5. As I considered the latter two of my bullet
> pointed remarks might well be bugs I upgraded to SDL 1.2.7.
Yes, all three of the issues involving clipping the overlay with the
rest of the desktop should have been fixed since I found that using a
blit instead of a true overlay was faster (?) possibly because of the
cost of directly accessing video ram.
> Under 1.2.7 I have a much greater problem - the same code on the same
> hardware and operating system now fails at SDL_DisplayYUVOverlay every
> time, returning -1.
What is the DirectX error being returned?
> Also, as I notice from reading the code that only 1x blitting and 2x
> blitting are supported for software overlay surfaces, perhaps the
> sentence in the doc project "If the dstrect is a larger or smaller than
> the overlay then the overlay will be scaled, this is optimized for 2x
> scaling." should be adjusted?
No, the software scaling works for all resolutions, it's just fastest
at 2X scaling.
> On a tangential note, I consider it unsatisfactory if I have to enable
> hardware overlays for myself and therefore build an sdl.dll which is
> different to everyone else's - to save myself a few minutes does anybody
> have a workspace that produces a statically linking version of SDL?
Yes, the hardware overlays were disabled on purpose to fix the desktop
clipping problems. Someone did submit code which used dst colorkey to
do the right thing but it was very slow for some reason.
Patches accepted! :)
-Sam Lantinga, Software Engineer, Blizzard Entertainment
More information about the SDL
mailing list