summaryrefslogtreecommitdiffstats
path: root/src/jogl/classes
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2012-10-12 21:44:07 +0200
committerSven Gothel <[email protected]>2012-10-12 21:44:07 +0200
commitd1537f0359f917e5a6b1e77852fa1b1ac8a54d5f (patch)
treedeff2016467921f9a44bfad491cde4a7d5406f9c /src/jogl/classes
parent1992d24671f8d99abccb671b8f9d5a7cd474fd00 (diff)
GLArrayDataClient.bindBuffer(gl, bind=true): checkSeal and init_vbo if required (similar sanity checks as enableBuffer())
Diffstat (limited to 'src/jogl/classes')
-rw-r--r--src/jogl/classes/com/jogamp/opengl/util/GLArrayDataClient.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/jogl/classes/com/jogamp/opengl/util/GLArrayDataClient.java b/src/jogl/classes/com/jogamp/opengl/util/GLArrayDataClient.java
index af091d52b..88cb3303f 100644
--- a/src/jogl/classes/com/jogamp/opengl/util/GLArrayDataClient.java
+++ b/src/jogl/classes/com/jogamp/opengl/util/GLArrayDataClient.java
@@ -182,6 +182,11 @@ public class GLArrayDataClient extends GLArrayDataWrapper implements GLArrayData
@Override
public boolean bindBuffer(GL gl, boolean bind) {
+ if(bind) {
+ checkSeal(true);
+ // init/generate VBO name if not done yet
+ init_vbo(gl);
+ }
return glArrayHandler.bindBuffer(gl, bind);
}