fixed errors.

JavaSaBr-added_new_var_type
JavaSaBr 7 years ago committed by Nehon
parent c6d255c5d8
commit 644663f871
  1. 2
      jme3-core/src/main/java/com/jme3/material/Material.java
  2. 13
      jme3-core/src/main/java/com/jme3/renderer/opengl/GLDebugDesktop.java
  3. 11
      jme3-jogl/src/main/java/com/jme3/renderer/jogl/JoglGL.java
  4. 10
      jme3-lwjgl/src/main/java/com/jme3/renderer/lwjgl/LwjglGL.java
  5. 10
      jme3-lwjgl3/src/main/java/com/jme3/renderer/lwjgl/LwjglGL.java

@ -798,7 +798,7 @@ public class Material implements CloneableSmartAsset, Cloneable, Savable {
if(type == VarType.ShaderStorageBufferObject) { if(type == VarType.ShaderStorageBufferObject) {
final StorageBlock storageBlock = shader.getStorageBlock(name); final StorageBlock storageBlock = shader.getStorageBlock(name);
storageBlock.setValue(param.getValue()); storageBlock.setStorageData(param.getValue());
} else { } else {

@ -108,6 +108,19 @@ public class GLDebugDesktop extends GLDebugES implements GL2, GL3, GL4 {
checkError(); checkError();
} }
@Override
public int glGetProgramResourceIndex(int program, int programInterface, String name) {
final int result = gl4.glGetProgramResourceIndex(program, programInterface, name);
checkError();
return result;
}
@Override
public void glShaderStorageBlockBinding(int program, int storageBlockIndex, int storageBlockBinding) {
gl4.glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
checkError();
}
public void glBlendEquationSeparate(int colorMode, int alphaMode) { public void glBlendEquationSeparate(int colorMode, int alphaMode) {
gl.glBlendEquationSeparate(colorMode, alphaMode); gl.glBlendEquationSeparate(colorMode, alphaMode);
checkError(); checkError();

@ -643,4 +643,15 @@ public class JoglGL implements GL, GL2, GL3, GL4 {
public void glBindBufferBase(final int target, final int index, final int buffer) { public void glBindBufferBase(final int target, final int index, final int buffer) {
GLContext.getCurrentGL().getGL3bc().glBindBufferBase(target, index, buffer); GLContext.getCurrentGL().getGL3bc().glBindBufferBase(target, index, buffer);
} }
@Override
public int glGetProgramResourceIndex(final int program, final int programInterface, final String name) {
throw new UnsupportedOperationException();
//return GLContext.getCurrentGL().getGL4bc().glGetProgramResourceIndex(program, programInterface, name);
}
@Override
public void glShaderStorageBlockBinding(final int program, final int storageBlockIndex, final int storageBlockBinding) {
GLContext.getCurrentGL().getGL4bc().glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
}
} }

@ -484,6 +484,16 @@ public final class LwjglGL implements GL, GL2, GL3, GL4 {
GL40.glPatchParameteri(GL40.GL_PATCH_VERTICES,count); GL40.glPatchParameteri(GL40.GL_PATCH_VERTICES,count);
} }
@Override
public int glGetProgramResourceIndex(final int program, final int programInterface, final String name) {
return GL43.glGetProgramResourceIndex(program, programInterface, name);
}
@Override
public void glShaderStorageBlockBinding(final int program, final int storageBlockIndex, final int storageBlockBinding) {
GL43.glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
}
@Override @Override
public void glDeleteVertexArrays(IntBuffer arrays) { public void glDeleteVertexArrays(IntBuffer arrays) {
checkLimit(arrays); checkLimit(arrays);

@ -616,6 +616,16 @@ public class LwjglGL extends LwjglRender implements GL, GL2, GL3, GL4 {
GL40.glPatchParameteri(GL40.GL_PATCH_VERTICES, count); GL40.glPatchParameteri(GL40.GL_PATCH_VERTICES, count);
} }
@Override
public int glGetProgramResourceIndex(final int program, final int programInterface, final String name) {
return GL43.glGetProgramResourceIndex(program, programInterface, name);
}
@Override
public void glShaderStorageBlockBinding(final int program, final int storageBlockIndex, final int storageBlockBinding) {
GL43.glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
}
@Override @Override
public void glDeleteVertexArrays(final IntBuffer arrays) { public void glDeleteVertexArrays(final IntBuffer arrays) {
checkLimit(arrays); checkLimit(arrays);

Loading…
Cancel
Save