SDL & OpenGL problem

Hi, probably this is an easy one, and little lame :wink:

Howto draw something in SDL ( ex. the foreground menus, texts, etc. ) on
the screen which was created with SDL_OPENGL flag. When i try to draw some
texts ( using SFont (SoFont actually )) and try to:


i just get Segmentation Fault(SDL Parachute Deployed) ;(. And it’s not
because of SoFont, it faults when only SDL_UpdateRect… is called.

The question is: WTF? Can I/Cannot I use SDL_UpdateRect when i use
SDL_OPENGL ? And simple:

doesn’t fail but doesn’t draw any text ;(.

Please, help.
Thanks in advance



You can’t do this with OpenGL. SDL only sets up a GL context (a window,
etc) for you, but you MUST use OpenGL calls to draw stuff!

Or you can use SDL_OPENGLBLIT, but we don’t want you to come back here in
a week and complain that it’s too slow, because it is.