summaryrefslogtreecommitdiffstats
path: root/src/java/com/sun/gluegen/opengl/GLConfiguration.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/java/com/sun/gluegen/opengl/GLConfiguration.java')
-rwxr-xr-xsrc/java/com/sun/gluegen/opengl/GLConfiguration.java18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/java/com/sun/gluegen/opengl/GLConfiguration.java b/src/java/com/sun/gluegen/opengl/GLConfiguration.java
index 3013848..9352bcb 100755
--- a/src/java/com/sun/gluegen/opengl/GLConfiguration.java
+++ b/src/java/com/sun/gluegen/opengl/GLConfiguration.java
@@ -59,7 +59,8 @@ public class GLConfiguration extends ProcAddressConfiguration {
// This directive is off by default but can help automatically
// indicate which extensions have been folded into the core OpenGL
// namespace, and if not, then why not
- private boolean autoUnifyExtensions;
+ private boolean autoUnifyExtensions=false;
+ private boolean allowNonGLExtensions=false;
public GLConfiguration(GLEmitter emitter) {
super();
@@ -82,6 +83,10 @@ public class GLConfiguration extends ProcAddressConfiguration {
String sym = readString("RenameExtensionIntoCore", tok, filename, lineNo);
extensionsRenamedIntoCore.add(sym);
}
+ else if (cmd.equalsIgnoreCase("AllowNonGLExtensions"))
+ {
+ allowNonGLExtensions = readBoolean("AllowNonGLExtensions", tok, filename, lineNo).booleanValue();
+ }
else if (cmd.equalsIgnoreCase("AutoUnifyExtensions"))
{
autoUnifyExtensions = readBoolean("AutoUnifyExtensions", tok, filename, lineNo).booleanValue();
@@ -209,14 +214,14 @@ public class GLConfiguration extends ProcAddressConfiguration {
ignoredExtensions.contains(extension)) {
return true;
}
- boolean isGLFunc = GLExtensionNames.isGLFunction(symbol);
boolean isGLEnum = GLExtensionNames.isGLEnumeration(symbol);
+ boolean isGLFunc = GLExtensionNames.isGLFunction(symbol);
if(isGLFunc || isGLEnum) {
if(GLExtensionNames.isExtensionVEN(symbol, isGLFunc)) {
String extSuffix = GLExtensionNames.getExtensionSuffix(symbol, isGLFunc);
if( getDropUniqVendorExtensions(extSuffix) ) {
if(DEBUG_IGNORES) {
- System.err.println("Ignore UniqVendorEXT: "+symbol);
+ System.err.println("Ignore UniqVendorEXT: "+symbol+", vendor "+extSuffix);
}
return true;
}
@@ -249,6 +254,13 @@ public class GLConfiguration extends ProcAddressConfiguration {
return autoUnifyExtensions;
}
+ /** If true, accept all non encapsulated defines and functions,
+ * as it is mandatory for GL declarations. */
+ public boolean getAllowNonGLExtensions() {
+ return allowNonGLExtensions;
+ }
+
+
/** shall the non unified (uniq) vendor extensions be dropped ? */
public boolean getDropUniqVendorExtensions(String extName) {
return dropUniqVendorExtensions.contains(extName);