headers for OpenGL, OpenAL, and SDL

Anders F Björklund afb at algonet.se
Mon Mar 6 02:45:13 PST 2006


Bruno Medeiros wrote:

> Hum, what are these headers different from those from Anders 
> (http://www.algonet.se/~afb/d/) or from Dporting 
> (http://shinh.skr.jp/d/porting.html) ?
> (well, the SDL version seems more recent, but still looks like 
> duplicated effort)

 From what I can tell from it, there are some differences both
in general (i.e. "how") and in coverage/license (i.e. "what")


They seem to be using the same kind of function pointers as
in Derelict, while my headers linked directly to the C libs...

i.e. the import module contains global function pointer entries,
and these are loaded from the DLL/SO at startup with std.loader

And these are in c.sdl and c.gl, mine were in sdl and opengl.
(there are also the derelict.sdl and derelict.opengl modules)


These OpenGL headers are based on Mesa 3-D and FreeGLUT, while
I used the SGI OpenGL 1.2.1 and GLUT 3.7 (both from opengl.org)

The licenses on these Open Source versions are much "nicer" than
the old ones, so that is really a good thing. They're newer, too.

They also included the GLX, WGL and AGL [empty now] extensions,
while I only included the GL/GLUT cross-platform variants in mine.


Oh, and these new ones don't support the Mac yet (maybe just Windows ?)
Tested mine (before) without any problems on Mac OS X, Linux and MinGW.

It's possible to add Mac support to these; by completing the AGL module,
and by adding support for calling the "SDL_main" hack (as usual) to SDL.

But I don't care much for the function pointers, though. Sorry... :-)
Understand they are handy on Windows, when you don't have the implibs.

--anders


PS.
I have SDL 1.2.9 in the CVS, so there shouldn't be any version diff ?
Haven't gotten around to updating the ZIPs, or fixing the DMD linking.



More information about the Digitalmars-d-announce mailing list