mac os x jogl implementation workaround

Hi,

jogl mac os x implementation has a serious problem:

it’s impossible to share jogl gl canvas with other awt components
JAWT MAC OS X implementation has a bug that is responsible for that problem
Gerard Ziemski informed us (java-dev list) earlier that he fixed that bug and new JAWT version will be available sometime after Panther release

meanwhile I implemented workaround to jogl mac os x sources

I put 2 modified files here:
http://www.concord.org/~dima/jogl/MacOSXOnscreenGLContext.java

http://www.concord.org/~dima/jogl/MacOSXWindowSystemInterface.m

here is what you have to do:

  1. backup your jogl.jar and libjogl.jnilib files

  2. backup your MacOSXOnscreenGLContext.java from
    <path_to_jogl_sources>/net/java/games/jogl/impl/macosx/MacOSXOnscreenGLContext.java
    replace old MacOSXOnscreenGLContext.java with new one from http://www.concord.org/~dima/jogl/MacOSXOnscreenGLContext.java

  3. backup your MacOSXWindowSystemInterface.m file from
    <path_to_jogl_sources>/native/jogl/MacOSXWindowSystemInterface.m
    replace old MacOSXWindowSystemInterface.m with new one from http://www.concord.org/~dima/jogl/MacOSXWindowSystemInterface.m

  4. remove old jogl.jar from the classpath

  5. remove old libjogl.jnilib from the library path

  6. remove build folder (<path_to_jogl>/build)

  7. go to make folder and call ant macosx

  8. wait for the few minutes

  9. install jogl.jar and libjogl.jnilib into the appropriate place:
    for example: /Library/Java/Extensions or ~/Library/Java/Extensions

  10. that’s it

it works for me

if you will have any problem don’t hesitate and send me email:
dmarkman@mac.com

additionally you can download binaries from:

http://www.concord.org/~dima/jogl/jogl.jar

http://www.concord.org/~dima/jogl/libjogl.jnilib

Dmitry Markman

I’ll see if I can diff those files with the ones in CVS and check in that change.