From: Michel B. <mic...@fr...> - 2009-01-01 09:47:12
|
Hi all, I've noted that OSX include now by default a very decent X11 server. Moreover it's open source and base on XOrg. You can install it from Apple official package (by default in Leopard) or you can download an updated version from http://xquartz.macosforge.org/trac/wiki. Why do I start with this ? This is because we can leverage a lot of code if we use X11/GLX to make OpenGL initialisation on Mac OSX as we do on Linux. On the other hand we can also continue with AGL or CGL that are Mac specifics layers to initialise OpenGL. This way Freewrl can keep it's "Mac" menu & "Mac" look & feel. Anyway, I've noted that the current code makes use of both AGL and CGL. You can find #ifdef garding blocks of code that either initialise OpenGL context with aglCreateContext or CGLCreateContext. There's currently a problem (freex3d crashes) in OpenGL initialisation because (obviously) of a race condition between threads. Context is not created before the first call to OpenGL (glEnableClientState at OpenGL_Utils.c:158). We should investigate how to remove that double dependency and choose only one : AGL or CGL. Maybe there a good reason to use both, but I doubt. I'm new to the Mac but I'm learning fast... I've read that one of theses library could write to fullscreen rendering context only. Cheers, Michel |