summaryrefslogtreecommitdiffstats
path: root/make/config/jogl/gl-impl-CustomJavaCode-gles3.java
diff options
context:
space:
mode:
Diffstat (limited to 'make/config/jogl/gl-impl-CustomJavaCode-gles3.java')
-rw-r--r--make/config/jogl/gl-impl-CustomJavaCode-gles3.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/make/config/jogl/gl-impl-CustomJavaCode-gles3.java b/make/config/jogl/gl-impl-CustomJavaCode-gles3.java
index 5c58f6cc4..83bdd7691 100644
--- a/make/config/jogl/gl-impl-CustomJavaCode-gles3.java
+++ b/make/config/jogl/gl-impl-CustomJavaCode-gles3.java
@@ -48,7 +48,7 @@ public final boolean isGLES1() {
@Override
public final boolean isGLES2() {
- return true;
+ return !_isES3;
}
@Override
@@ -255,7 +255,16 @@ private final boolean checkBufferObject(boolean extensionAvail,
}
}
+private final void validateCPUSourcedAvail() {
+ if(!_context.isCPUDataSourcingAvail()) {
+ throw new GLException("CPU data sourcing n/a w/ "+_context);
+ }
+}
+
private final boolean checkArrayVBOUnbound(boolean throwException) {
+ if(throwException) {
+ validateCPUSourcedAvail();
+ }
return checkBufferObject(true,
_isES3, // allowVAO
false, // bound
@@ -272,6 +281,9 @@ private final boolean checkArrayVBOBound(boolean throwException) {
}
private final boolean checkElementVBOUnbound(boolean throwException) {
+ if(throwException) {
+ validateCPUSourcedAvail();
+ }
return checkBufferObject(true,
_isES3, // allowVAO
false, // bound