summaryrefslogtreecommitdiffstats
path: root/make/config/jogl
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-10-06 15:56:44 +0200
committerSven Gothel <[email protected]>2013-10-06 15:56:44 +0200
commit1259693f21734b0ebe1b5c95688ad91956c2629c (patch)
tree292b63912a7c9d67a9cf37ac054b8e344b282aac /make/config/jogl
parentff86d8398ce66abddff4cbada8eabd1314a11d7b (diff)
Bug 789: glDrawArraysIndirect and glDrawElementsIndirect are using GL_DRAW_INDIRECT_BUFFER, add VBO variant and range-check
Diffstat (limited to 'make/config/jogl')
-rw-r--r--make/config/jogl/gl-common.cfg6
-rw-r--r--make/config/jogl/gl-impl-CustomJavaCode-gl4bc.java16
2 files changed, 22 insertions, 0 deletions
diff --git a/make/config/jogl/gl-common.cfg b/make/config/jogl/gl-common.cfg
index a1b09c5b4..b84115445 100644
--- a/make/config/jogl/gl-common.cfg
+++ b/make/config/jogl/gl-common.cfg
@@ -591,6 +591,9 @@ BufferObjectKind Element glDrawElementsInstancedBaseVertexBaseInstance
BufferObjectKind Element glDrawRangeElements
BufferObjectKind Element glDrawRangeElementsBaseVertex
+BufferObjectKind Indirect glDrawArraysIndirect
+BufferObjectKind Indirect glDrawElementsIndirect
+
# There are no PBOs in the embedded OpenGL variants right now
BufferObjectKind UnpackPixel glBitmap
BufferObjectKind UnpackPixel glColorTable
@@ -651,6 +654,9 @@ RangeCheck glDrawElementsInstancedBaseVertexBaseInstance 3 {1}
RangeCheck glDrawRangeElements 5 {3}
RangeCheck glDrawRangeElementsBaseVertex 5 {3}
+RangeCheck glDrawArraysIndirect 1 1
+RangeCheck glDrawElementsIndirect 2 1
+
RangeCheck glEdgeFlagPointer 1 1
RangeCheck glElementPointerATI 1 1
RangeCheck glFogCoordPointer 2 1
diff --git a/make/config/jogl/gl-impl-CustomJavaCode-gl4bc.java b/make/config/jogl/gl-impl-CustomJavaCode-gl4bc.java
index d1a4ceda0..c769ddcfa 100644
--- a/make/config/jogl/gl-impl-CustomJavaCode-gl4bc.java
+++ b/make/config/jogl/gl-impl-CustomJavaCode-gl4bc.java
@@ -366,6 +366,22 @@ private final boolean checkElementVBOBound(boolean throwException) {
"element vertex_buffer_object", throwException);
}
+private final boolean checkIndirectVBOUnbound(boolean throwException) {
+ return checkBufferObject(haveGL15 || haveARBVertexBufferObject,
+ haveARBVertexArrayObject, // allowVAO
+ false, // bound
+ GL4.GL_DRAW_INDIRECT_BUFFER,
+ "indirect vertex_buffer_object", throwException);
+}
+
+private final boolean checkIndirectVBOBound(boolean throwException) {
+ return checkBufferObject(haveGL15 || haveARBVertexBufferObject,
+ haveARBVertexArrayObject, // allowVAO
+ true, // bound
+ GL4.GL_DRAW_INDIRECT_BUFFER,
+ "indirect vertex_buffer_object", throwException);
+}
+
private final boolean checkUnpackPBOUnbound(boolean throwException) {
return checkBufferObject(haveGL21 || haveARBPixelBufferObject || haveEXTPixelBufferObject,
false, // allowVAO