diff options
author | Kenneth Russel <[email protected]> | 2009-01-12 00:51:20 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2009-01-12 00:51:20 +0000 |
commit | 612955ad82326024f5cb99d9fe4175dce78caa27 (patch) | |
tree | 941c15a6eb8f1c17b739e7a9b73feebedb7d40e9 /src/demos | |
parent | c5cb640a428bf9b6d398616dc542ea529a2036d2 (diff) |
Fixed ArgumentIsString directive for glProgramStringARB (now
glProgramString) and updated demos. Added FIXME to
gl-ignore-gl2_es12-special.cfg about definitions that it seems should
be in the GL interface (such as the GL_ARB_imaging definitions) as
they are replicated in the GL2ES1 and GL2ES2 interfaces.
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/../svn-server-sync/jogl-demos/branches/JOGL_2_SANDBOX@315 3298f667-5e0e-4b4a-8ed4-a3559d26a5f4
Diffstat (limited to 'src/demos')
-rw-r--r-- | src/demos/proceduralTexturePhysics/Water.java | 3 | ||||
-rw-r--r-- | src/demos/vertexProgRefract/VertexProgRefract.java | 4 | ||||
-rw-r--r-- | src/demos/vertexProgWarp/VertexProgWarp.java | 2 |
3 files changed, 4 insertions, 5 deletions
diff --git a/src/demos/proceduralTexturePhysics/Water.java b/src/demos/proceduralTexturePhysics/Water.java index bf6f980..42fb785 100644 --- a/src/demos/proceduralTexturePhysics/Water.java +++ b/src/demos/proceduralTexturePhysics/Water.java @@ -1817,8 +1817,7 @@ public class Water { int target, String programBuffer) { - ByteBuffer bb = BufferUtil.newByteBuffer(programBuffer.getBytes()); - gl.glProgramString(target, GL2.GL_PROGRAM_FORMAT_ASCII, programBuffer.length(), bb); + gl.glProgramString(target, GL2.GL_PROGRAM_FORMAT_ASCII, programBuffer.length(), programBuffer); int[] errPos = new int[1]; gl.glGetIntegerv(GL2.GL_PROGRAM_ERROR_POSITION, errPos, 0); diff --git a/src/demos/vertexProgRefract/VertexProgRefract.java b/src/demos/vertexProgRefract/VertexProgRefract.java index 757534f..ce1c975 100644 --- a/src/demos/vertexProgRefract/VertexProgRefract.java +++ b/src/demos/vertexProgRefract/VertexProgRefract.java @@ -285,7 +285,7 @@ public class VertexProgRefract extends Demo { vtxProg = vtxProgTmp[0]; gl.glBindProgram(GL2.GL_VERTEX_PROGRAM, vtxProg); gl.glProgramString(GL2.GL_VERTEX_PROGRAM, GL2.GL_PROGRAM_FORMAT_ASCII, transformRefract.length(), - BufferUtil.newByteBuffer(transformRefract.getBytes())); + transformRefract); gl.glProgramEnvParameter4f(GL2.GL_VERTEX_PROGRAM, 0, 0.0f, 0.0f, 0.0f, 1.0f); // eye position @@ -580,7 +580,7 @@ public class VertexProgRefract extends Demo { gl.glBindProgram(GL2.GL_FRAGMENT_PROGRAM, fragProg); gl.glProgramString(GL2.GL_FRAGMENT_PROGRAM, GL2.GL_PROGRAM_FORMAT_ASCII, - combineFragProg.length(), BufferUtil.newByteBuffer(combineFragProg.getBytes())); + combineFragProg.length(), combineFragProg); int[] errPos = new int[1]; gl.glGetIntegerv(GL2.GL_PROGRAM_ERROR_POSITION, errPos, 0); if (errPos[0] >= 0) { diff --git a/src/demos/vertexProgWarp/VertexProgWarp.java b/src/demos/vertexProgWarp/VertexProgWarp.java index 7bbb4b3..43a7183 100644 --- a/src/demos/vertexProgWarp/VertexProgWarp.java +++ b/src/demos/vertexProgWarp/VertexProgWarp.java @@ -196,7 +196,7 @@ public class VertexProgWarp extends Demo { programs[i] = vtxProgTmp[0]; gl.glBindProgram(GL2.GL_VERTEX_PROGRAM, programs[i]); gl.glProgramString(GL2.GL_VERTEX_PROGRAM, GL2.GL_PROGRAM_FORMAT_ASCII, programTexts[i].length(), - BufferUtil.newByteBuffer(programTexts[i].getBytes())); + programTexts[i]); } gl.glProgramEnvParameter4f(GL2.GL_VERTEX_PROGRAM, 0, 0.0f, 0.0f, 1.0f, 0.0f); // light position/direction |