OpenGL options

I have been using SDL for about a year now and have come to a point where I
want to start OpenGL. It is my understanding that SDL makes a great front
end for GL. What I was curious about is this. Is it better to use the SDL
OpenGL headers or directly use the GL headers? Or is there any difference at
all? Thanks for any help.

Steven

Using the OpenGL headers directly is platform dependent. SDL_opengl.h
is just a thin wrapper that does the right thing on whatever platform
you’re building on.

(The version I’m looking at right now actually contains what seems
to be a complete OpenGL API header, including various platform and
driver/card specific extensions.)

Using this is, AFAIK, the correct way to use OpenGL with current SDL
versions.

//David Olofson - Programmer, Composer, Open Source Advocate

.- Audiality -----------------------------------------------.
| Free/Open Source audio engine for games and multimedia. |
| MIDI, modular synthesis, real time effects, scripting,… |
`-----------------------------------> http://audiality.org -’
http://olofson.nethttp://www.reologica.se —On Monday 21 March 2005 14.04, AIM1 BRADLEY wrote:

I have been using SDL for about a year now and have come to a point
where I want to start OpenGL. It is my understanding that SDL makes
a great front end for GL. What I was curious about is this. Is it
better to use the SDL OpenGL headers or directly use the GL headers?
Or is there any difference at all? Thanks for any help.

I have been using SDL for about a year now and have come to a point where I
want to start OpenGL. It is my understanding that SDL makes a great front
end for GL. What I was curious about is this. Is it better to use the SDL
OpenGL headers or directly use the GL headers? Or is there any difference at
all? Thanks for any help.

AFAIK it isn’t very big difference - I’ve been using normal GL headers and it worked, and I’ve been using SDL GL headers and it worked too :slight_smile:

However, using SDL GL headers you are better in that your sources are more portable - you can use them on win32, Linux, MacOS etc. without doing in your own code things, such as those lovely few lines in SDL_opnegl.h that start with #ifdef WIN32 …

Koshmaar