aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-x[-rw-r--r--]src/classes/com/sun/opengl/impl/DRIHack.java (renamed from src/classes/com/sun/opengl/impl/x11/glx/DRIHack.java)4
-rw-r--r--src/classes/com/sun/opengl/impl/macosx/cgl/MacOSXCGLDrawableFactory.java4
-rw-r--r--src/classes/com/sun/opengl/impl/windows/wgl/WindowsWGLDrawableFactory.java4
-rw-r--r--src/classes/com/sun/opengl/impl/x11/glx/X11GLXDrawableFactory.java9
-rw-r--r--src/classes/javax/media/opengl/GLProfile.java7
5 files changed, 8 insertions, 20 deletions
diff --git a/src/classes/com/sun/opengl/impl/x11/glx/DRIHack.java b/src/classes/com/sun/opengl/impl/DRIHack.java
index 120d93942..5478bd2f3 100644..100755
--- a/src/classes/com/sun/opengl/impl/x11/glx/DRIHack.java
+++ b/src/classes/com/sun/opengl/impl/DRIHack.java
@@ -37,13 +37,11 @@
* and developed by Kenneth Bradley Russell and Christopher John Kline.
*/
-package com.sun.opengl.impl.x11.glx;
+package com.sun.opengl.impl;
import java.io.*;
import java.security.*;
import com.sun.gluegen.runtime.*;
-import com.sun.opengl.impl.*;
-import com.sun.opengl.impl.x11.*;
/**
* Helper class for working around problems with open-source DRI
diff --git a/src/classes/com/sun/opengl/impl/macosx/cgl/MacOSXCGLDrawableFactory.java b/src/classes/com/sun/opengl/impl/macosx/cgl/MacOSXCGLDrawableFactory.java
index 2880ee0ed..5e47a4bbb 100644
--- a/src/classes/com/sun/opengl/impl/macosx/cgl/MacOSXCGLDrawableFactory.java
+++ b/src/classes/com/sun/opengl/impl/macosx/cgl/MacOSXCGLDrawableFactory.java
@@ -46,10 +46,6 @@ import javax.media.opengl.*;
import com.sun.opengl.impl.*;
public class MacOSXCGLDrawableFactory extends GLDrawableFactoryImpl {
- static {
- NativeLibLoader.loadGL2();
- }
-
public MacOSXCGLDrawableFactory() {
super();
}
diff --git a/src/classes/com/sun/opengl/impl/windows/wgl/WindowsWGLDrawableFactory.java b/src/classes/com/sun/opengl/impl/windows/wgl/WindowsWGLDrawableFactory.java
index a13aba0e4..762714690 100644
--- a/src/classes/com/sun/opengl/impl/windows/wgl/WindowsWGLDrawableFactory.java
+++ b/src/classes/com/sun/opengl/impl/windows/wgl/WindowsWGLDrawableFactory.java
@@ -53,10 +53,6 @@ public class WindowsWGLDrawableFactory extends GLDrawableFactoryImpl {
// FIXME: this should go away once we delete support for the C GLU library
private long hglu32;
- static {
- NativeLibLoader.loadGL2();
- }
-
public WindowsWGLDrawableFactory() {
super();
}
diff --git a/src/classes/com/sun/opengl/impl/x11/glx/X11GLXDrawableFactory.java b/src/classes/com/sun/opengl/impl/x11/glx/X11GLXDrawableFactory.java
index d68f087b6..008cb9c2b 100644
--- a/src/classes/com/sun/opengl/impl/x11/glx/X11GLXDrawableFactory.java
+++ b/src/classes/com/sun/opengl/impl/x11/glx/X11GLXDrawableFactory.java
@@ -85,15 +85,6 @@ public class X11GLXDrawableFactory extends GLDrawableFactoryImpl {
long visualID() { return visualID; }
}
- static {
- // See DRIHack.java for an explanation of why this is necessary
- DRIHack.begin();
-
- com.sun.opengl.impl.NativeLibLoader.loadGL2();
-
- DRIHack.end();
- }
-
public X11GLXDrawableFactory() {
super();
// Must initialize GLX support eagerly in case a pbuffer is the
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;
}
}