[SDL] OpenGL textures, where do they go?
dfnsonfsduifb at gmx.de
Wed Dec 8 17:16:13 PST 2004
I'm using SDL with OpenGL in a game of mine because OpenGL gives great
HW-accelerated performance. Now in order to reuse my old style blitting
methods, I wrote a wrapper which converts SDL_Surface* to GL-Textures
and then blits them.
After the conversion of a SDL_Surface* to a GLuint texture handle, the
original surface can be discarded.
This I fear, very much. Because it means the texture needs to be stored
somewhere. I guess the graphics' card memory, right? Now what if it
fills up? Will the application crash? Now be able to create any more
textures? Or is it so "smart" that it can temporarily "swap-out"
textures and swap them in on demand? What about thrashing?
SDL_Surfaces are just sooooo much easier ;-)
More information about the SDL