Surface locks (was Re: [SDL] Re: When will there be blitting support when using OpenGL)

vining at pacificcoast.net vining at pacificcoast.net
Wed Apr 5 13:49:04 PDT 2000


>vining at pacificcoast.net wrote:
>
>> Unfortunately, not true. We have no way of guaranteeing that an
>> SDL_Surface has not changed since the last upload (since we can
>> access the surface's pixels directly without going through another
>> API), therefore we would need to constantly re-upload. A cruel world.
>> As for necessity, you're right, but if you wanted to do something
>> like rewrite SDL's video aspect to do 2D blits on top of OpenGL you
>> would have to. Sucky.
>
>Actually, I already suggested to Sam that forcing people to use a
>Lock/Unlock kind of operation would be a nice idea and would enable some
>drivers to accelerate cases like these (for exemple, in raw Xlib,
>Pixmaps can be faster than shared memory with XF86 4.0, and just as fast
>with pre-4.0).

... not a bad idea (a pain in the ass for users, but not a bad idea...) however 
I doubt you could do this without breaking applications which used an older 
SDL. Sam?

Nicholas






More information about the SDL mailing list