summaryrefslogtreecommitdiffstats
path: root/make/config/jogl
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-11-08 23:47:31 +0100
committerSven Gothel <[email protected]>2011-11-08 23:47:31 +0100
commit297c97d28bb3490177b5ff9441f3d6494d09b819 (patch)
treec171044cdd52d0a3c2232d6c3de3bffdf1aea161 /make/config/jogl
parent48c2ba5ee339487ef56ba58d861cb923e3d0c432 (diff)
JOGL: GLBase Add 'isNPOTTextureAvailable()' for convenience
Diffstat (limited to 'make/config/jogl')
-rw-r--r--make/config/jogl/gl-impl-CustomJavaCode-common.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/make/config/jogl/gl-impl-CustomJavaCode-common.java b/make/config/jogl/gl-impl-CustomJavaCode-common.java
index 0a8e90171..0878bd236 100644
--- a/make/config/jogl/gl-impl-CustomJavaCode-common.java
+++ b/make/config/jogl/gl-impl-CustomJavaCode-common.java
@@ -35,6 +35,11 @@
return _context.isExtensionAvailable(glExtensionName);
}
+ public boolean isNPOTTextureAvailable() {
+ return isGL3() || isGLES2() || isExtensionAvailable(GL_ARB_texture_non_power_of_two);
+ }
+ private static final String GL_ARB_texture_non_power_of_two = "GL_ARB_texture_non_power_of_two";
+
public Object getExtension(String extensionName) {
// At this point we don't expose any extensions using this mechanism
return null;