aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl
diff options
context:
space:
mode:
Diffstat (limited to 'src/jogl')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/GLDrawableFactory.java38
-rw-r--r--src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java60
2 files changed, 54 insertions, 44 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/GLDrawableFactory.java b/src/jogl/classes/com/jogamp/opengl/GLDrawableFactory.java
index 07c3e77e0..7d78e3409 100644
--- a/src/jogl/classes/com/jogamp/opengl/GLDrawableFactory.java
+++ b/src/jogl/classes/com/jogamp/opengl/GLDrawableFactory.java
@@ -144,23 +144,29 @@ public abstract class GLDrawableFactory {
}
}
}
- if (null != factoryClassName && !GLProfile.disableOpenGLDesktop) {
- if (DEBUG || GLProfile.DEBUG) {
- System.err.println("GLDrawableFactory.static - Native OS Factory for: "+nwt+": "+factoryClassName);
- }
- try {
- tmp = (GLDrawableFactory) ReflectionUtil.createInstance(factoryClassName, cl);
- } catch (final Exception jre) {
- if (DEBUG || GLProfile.DEBUG) {
- System.err.println("Info: GLDrawableFactory.static - Native Platform: "+nwt+" - not available: "+factoryClassName);
- jre.printStackTrace();
- }
- }
- }
- if(null != tmp && tmp.isComplete()) {
- nativeOSFactory = tmp;
+ if ( !GLProfile.disableOpenGLDesktop ) {
+ if ( null != factoryClassName ) {
+ if (DEBUG || GLProfile.DEBUG) {
+ System.err.println("GLDrawableFactory.static - Native OS Factory for: "+nwt+": "+factoryClassName);
+ }
+ try {
+ tmp = (GLDrawableFactory) ReflectionUtil.createInstance(factoryClassName, cl);
+ } catch (final Exception jre) {
+ if (DEBUG || GLProfile.DEBUG) {
+ System.err.println("Info: GLDrawableFactory.static - Native Platform: "+nwt+" - not available: "+factoryClassName);
+ jre.printStackTrace();
+ }
+ }
+ if(null != tmp && tmp.isComplete()) {
+ nativeOSFactory = tmp;
+ }
+ tmp = null;
+ } else if( DEBUG || GLProfile.DEBUG ) {
+ System.err.println("Info: GLDrawableFactory.static - Desktop GLDrawableFactory unspecified!");
+ }
+ } else if( DEBUG || GLProfile.DEBUG ) {
+ System.err.println("Info: GLDrawableFactory.static - Desktop GLDrawableFactory - disabled!");
}
- tmp = null;
if(!GLProfile.disableOpenGLES) {
try {
diff --git a/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java b/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java
index 8e2535309..4fecafdfc 100644
--- a/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java
+++ b/src/jogl/classes/jogamp/opengl/egl/EGLDrawableFactory.java
@@ -284,40 +284,44 @@ public class EGLDrawableFactory extends GLDrawableFactoryImpl {
}
// Setup: eglGLnDynamicLookupHelper
if( null == eglGLnDynamicLookupHelper ) {
- GLDynamicLookupHelper tmp=null;
- try {
- tmp = new GLDynamicLookupHelper(new EGLGLnDynamicLibraryBundleInfo());
- } catch (final GLException gle) {
- if(DEBUG) {
- gle.printStackTrace();
+ if( !GLProfile.disableOpenGLDesktop ) {
+ GLDynamicLookupHelper tmp=null;
+ try {
+ tmp = new GLDynamicLookupHelper(new EGLGLnDynamicLibraryBundleInfo());
+ } catch (final GLException gle) {
+ if(DEBUG) {
+ gle.printStackTrace();
+ }
}
- }
- if( null != tmp && tmp.isLibComplete() ) {
- final boolean ok;
- final long _eglInitializeAddress;
- if( !eglTableReset ) {
- if( true == ( eglTableReset = EGLAcc.resetProcAddressTable(tmp) ) ) {
- _eglInitializeAddress = tmp.dynamicLookupFunction(eglInitializeFuncName);
- eglInitializeAddress = _eglInitializeAddress;
- ok = true;
+ if( null != tmp && tmp.isLibComplete() ) {
+ final boolean ok;
+ final long _eglInitializeAddress;
+ if( !eglTableReset ) {
+ if( true == ( eglTableReset = EGLAcc.resetProcAddressTable(tmp) ) ) {
+ _eglInitializeAddress = tmp.dynamicLookupFunction(eglInitializeFuncName);
+ eglInitializeAddress = _eglInitializeAddress;
+ ok = true;
+ } else {
+ _eglInitializeAddress = 0;
+ ok = false;
+ }
} else {
- _eglInitializeAddress = 0;
- ok = false;
+ _eglInitializeAddress = tmp.dynamicLookupFunction(eglInitializeFuncName);
+ ok = _eglInitializeAddress == eglInitializeAddress;
}
- } else {
- _eglInitializeAddress = tmp.dynamicLookupFunction(eglInitializeFuncName);
- ok = _eglInitializeAddress == eglInitializeAddress;
- }
- if( ok ) {
- eglGLnDynamicLookupHelper = tmp;
- if (DEBUG || GLProfile.DEBUG) {
- System.err.println("Info: EGLDrawableFactory: EGL GLn - OK (eglTableReset "+eglTableReset+", eglInitialize 0x"+Long.toHexString(_eglInitializeAddress)+")");
+ if( ok ) {
+ eglGLnDynamicLookupHelper = tmp;
+ if (DEBUG || GLProfile.DEBUG) {
+ System.err.println("Info: EGLDrawableFactory: EGL GLn - OK (eglTableReset "+eglTableReset+", eglInitialize 0x"+Long.toHexString(_eglInitializeAddress)+")");
+ }
+ } else if (DEBUG || GLProfile.DEBUG) {
+ System.err.println("Info: EGLDrawableFactory: EGL GLn - NOPE (GLn proc, eglTableReset "+eglTableReset+", eglInitialize 0x"+Long.toHexString(_eglInitializeAddress)+")");
}
} else if (DEBUG || GLProfile.DEBUG) {
- System.err.println("Info: EGLDrawableFactory: EGL GLn - NOPE (GLn proc, eglTableReset "+eglTableReset+", eglInitialize 0x"+Long.toHexString(_eglInitializeAddress)+")");
+ System.err.println("Info: EGLDrawableFactory: EGL GLn - NOPE (GLn lib)");
}
- } else if (DEBUG || GLProfile.DEBUG) {
- System.err.println("Info: EGLDrawableFactory: EGL GLn - NOPE (GLn lib)");
+ } else if( DEBUG || GLProfile.DEBUG ) {
+ System.err.println("Info: EGLDrawableFactory: EGL Gln - disabled!");
}
}
if( null != eglES2DynamicLookupHelper || null != eglES1DynamicLookupHelper || null != eglGLnDynamicLookupHelper ) {