Added yet another glGetActiveUniform alternative.

This commit is contained in:
Ioannis Tsakpinis 2010-03-31 20:56:07 +00:00
parent 6e738cc2b6
commit 37489e8c94
3 changed files with 23 additions and 1 deletions

View File

@ -45,7 +45,7 @@ import org.lwjgl.opengl.Display;
* $Id$
*/
final class WindowsSysImplementation extends DefaultSysImplementation {
private final static int JNI_VERSION = 22;
private final static int JNI_VERSION = 22;
static {
Sys.initialize();

View File

@ -227,6 +227,16 @@ public interface ARB_shader_objects {
@OutParameter @GLenum @Check("1") IntBuffer type,
@OutParameter @GLcharARB ByteBuffer name);
/** This version returns both size and type in the sizeType buffer (at .position() and .position() + 1). */
@Alternate("glGetActiveUniformARB")
@GLreturn(value = "name", maxLength = "maxLength")
void glGetActiveUniformARB3(@GLhandleARB int programObj, @GLuint int index, @GLsizei int maxLength,
@OutParameter @GLsizei @Constant("name_length, 0") IntBuffer length,
@OutParameter @Check("2") IntBuffer sizeType,
@OutParameter @GLenum @Constant("sizeType, sizeType.position() + 1") IntBuffer type,
@OutParameter @GLcharARB ByteBuffer name);
/** This version returns only the uniform size. */
@Alternate(value = "glGetActiveUniformARB", javaAlt = true)
@GLreturn(value = "size")
void glGetActiveUniformSizeARB(@GLhandleARB int programObj, @GLuint int index, @Constant("0") @GLsizei int maxLength,
@ -235,6 +245,7 @@ public interface ARB_shader_objects {
@OutParameter @GLenum @Constant("size, 1") IntBuffer type, // Reuse size buffer and ignore
@GLcharARB @Constant("APIUtils.getBufferByte(0), 0") ByteBuffer name);
/** This version returns only the uniform type. */
@Alternate(value = "glGetActiveUniformARB", javaAlt = true)
@GLreturn(value = "type")
void glGetActiveUniformTypeARB(@GLhandleARB int programObj, @GLuint int index, @Constant("0") @GLsizei int maxLength,

View File

@ -250,6 +250,16 @@ public interface GL20 {
@OutParameter @GLenum @Check("1") IntBuffer type,
@OutParameter @GLchar ByteBuffer name);
/** This version returns both size and type in the sizeType buffer (at .position() and .position() + 1). */
@Alternate("glGetActiveUniformARB")
@GLreturn(value = "name", maxLength = "maxLength")
void glGetActiveUniform3(@GLuint int program, @GLuint int index, @GLsizei int maxLength,
@OutParameter @GLsizei @Constant("name_length, 0") IntBuffer length,
@OutParameter @Check("2") IntBuffer sizeType,
@OutParameter @GLenum @Constant("sizeType, sizeType.position() + 1") IntBuffer type,
@OutParameter @GLchar ByteBuffer name);
/** This version returns only the uniform size. */
@Alternate(value = "glGetActiveUniform", javaAlt = true)
@GLreturn(value = "size")
void glGetActiveUniformSize(@GLuint int program, @GLuint int index, @Constant("0") @GLsizei int maxLength,
@ -258,6 +268,7 @@ public interface GL20 {
@OutParameter @GLenum @Constant("size, 1") IntBuffer type, // Reuse size buffer and ignore
@GLchar @Constant("APIUtils.getBufferByte(0), 0") ByteBuffer name);
/** This version returns only the uniform type. */
@Alternate(value = "glGetActiveUniform", javaAlt = true)
@GLreturn(value = "type")
void glGetActiveUniformType(@GLuint int program, @GLuint int index, @Constant("0") @GLsizei int maxLength,