From 25e894d4355318c50d847da5deda6cd1a0d9afba Mon Sep 17 00:00:00 2001 From: Kenneth Russel Date: Fri, 8 Aug 2008 22:51:16 +0000 Subject: Removed unnecessary GL2 dependencies from desktop window system code. Moved Linux-specific DRIHack into shared code so it could be called from the common code path in GLProfile which now loads the shared libraries. Temporarily ignored WGL_OML_sync_control and WGL_NV_gpu_affinity extensions to avoid dependencies on NIO classes (java.nio.LongBuffer) not in CDC/FP/JSR-239 NIO profile. Can now run JOGL with CVM on the desktop. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1743 232f8b59-042b-4e1e-8c03-345bb8c30851 --- src/classes/javax/media/opengl/GLProfile.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/classes/javax/media/opengl/GLProfile.java') diff --git a/src/classes/javax/media/opengl/GLProfile.java b/src/classes/javax/media/opengl/GLProfile.java index 67e427f5a..aec2a7789 100644 --- a/src/classes/javax/media/opengl/GLProfile.java +++ b/src/classes/javax/media/opengl/GLProfile.java @@ -61,7 +61,10 @@ public class GLProfile { try { Class clazz = Class.forName(getGLImplBaseClassName()+"Impl"); if(GL2.equals(profile)) { + // See DRIHack.java for an explanation of why this is necessary + DRIHack.begin(); NativeLibLoader.loadGL2(); + DRIHack.end(); } if(GL2ES12.equals(profile)) { NativeLibLoader.loadGL2ES12(); } else if(GLES1.equals(profile) || GLES2.equals(profile)) { @@ -70,7 +73,11 @@ public class GLProfile { throw new GLException("com.sun.opengl.impl.egl.EGLDrawableFactory not available"); } } + System.out.println("Successfully loaded profile " + profile); } catch (Throwable e) { + if (Debug.debug("GLProfile")) { + e.printStackTrace(); + } profile=null; } } -- cgit v1.2.3