From 16e5b7e6c14497b932f58ed38fc03c48656fdb09 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Mon, 22 Aug 2011 16:48:15 +0200 Subject: Fix regression of commit 6c346d98f04e2355210960fe9ffde47432f04d62, where GLDataArrayHandler throws an exception in cstr if not VBO, but VBO usage is determined later --- make/scripts/tests.sh | 4 ++-- src/jogl/classes/jogamp/opengl/util/GLDataArrayHandler.java | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/make/scripts/tests.sh b/make/scripts/tests.sh index 161198580..36c5a21ca 100755 --- a/make/scripts/tests.sh +++ b/make/scripts/tests.sh @@ -142,7 +142,7 @@ function testawtmt() { #testnoawt com.jogamp.opengl.test.junit.newt.TestRemoteGLWindows01NEWT $* #testawt com.jogamp.opengl.test.junit.jogl.demos.gl2.newt.TestGearsNEWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.demos.gl2.newt.TestGearsNEWT $* -testnoawt com.jogamp.opengl.test.junit.jogl.demos.es1.newt.TestGearsES1NEWT $* +#testnoawt com.jogamp.opengl.test.junit.jogl.demos.es1.newt.TestGearsES1NEWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $* #testnoawt com.jogamp.opengl.test.junit.newt.TestGLWindows02NEWTAnimated $* #testawt com.jogamp.opengl.test.junit.newt.TestDisplayLifecycle01NEWT @@ -220,7 +220,7 @@ testnoawt com.jogamp.opengl.test.junit.jogl.demos.es1.newt.TestGearsES1NEWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.glsl.TestRulerNEWT01 $* #testnoawt com.jogamp.opengl.test.junit.jogl.glsl.TestFBOMRTNEWT01 $* -#testnoawt com.jogamp.opengl.test.junit.graph.TestRegionRendererNEWT01 $* +testnoawt com.jogamp.opengl.test.junit.graph.TestRegionRendererNEWT01 $* #testnoawt com.jogamp.opengl.test.junit.graph.TestTextRendererNEWT01 $* #testnoawt com.jogamp.opengl.test.junit.graph.demos.ui.UINewtDemo01 $* #testnoawt com.jogamp.opengl.test.junit.graph.demos.GPUTextNewtDemo01 $* diff --git a/src/jogl/classes/jogamp/opengl/util/GLDataArrayHandler.java b/src/jogl/classes/jogamp/opengl/util/GLDataArrayHandler.java index 259b8ae23..d114abe4d 100644 --- a/src/jogl/classes/jogamp/opengl/util/GLDataArrayHandler.java +++ b/src/jogl/classes/jogamp/opengl/util/GLDataArrayHandler.java @@ -43,10 +43,6 @@ public class GLDataArrayHandler implements GLArrayHandler { public GLDataArrayHandler(GLArrayDataEditable ad) { this.ad = ad; - if(!ad.isVBO()) { - // makes no sense otherwise - throw new GLException("GLDataArrayHandler can only handle VBOs."); - } } public final void addSubHandler(GLArrayHandler handler) { @@ -54,6 +50,10 @@ public class GLDataArrayHandler implements GLArrayHandler { } public final void syncData(GL gl, boolean enable) { + if(!ad.isVBO()) { + // makes no sense otherwise + throw new GLException("GLDataArrayHandler can only handle VBOs."); + } if(enable) { Buffer buffer = ad.getBuffer(); -- cgit v1.2.3