Top Description Fields Constructors Methods
org.lwjgl.opengl

public Class ARBShaderSubroutine

extends Object
Class Inheritance
Imports
javax.annotation.*, java.nio.*, org.lwjgl.system.*

Native bindings to the ARB_shader_subroutine extension.

This extension adds support to shaders for "indirect subroutine calls", where a single shader can include many subroutines and dynamically select through the API which subroutine is called from each call site. Switching subroutines dynamically in this fashion can avoid the cost of recompiling and managing multiple shaders, while still retaining most of the performance of specialized shaders.

Requires ARB_gpu_shader5. Promoted to core in OpenGL 4.0.

Field Summary

Modifier and TypeField and Description
public static final int
GL_ACTIVE_SUBROUTINE_MAX_LENGTH

Accepted by the pname parameter of GetProgramStageiv.

public static final int
GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS

Accepted by the pname parameter of GetProgramStageiv.

public static final int
GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH

Accepted by the pname parameter of GetProgramStageiv.

public static final int
GL_ACTIVE_SUBROUTINE_UNIFORMS

Accepted by the pname parameter of GetProgramStageiv.

public static final int
GL_ACTIVE_SUBROUTINES

Accepted by the pname parameter of GetProgramStageiv.

public static final int
GL_COMPATIBLE_SUBROUTINES

Accepted by the pname parameter of GetActiveSubroutineUniformiv.

public static final int
GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetFloatv, GetDoublev, and GetInteger64v.

public static final int
GL_MAX_SUBROUTINES

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetFloatv, GetDoublev, and GetInteger64v.

public static final int
GL_NUM_COMPATIBLE_SUBROUTINES

Accepted by the pname parameter of GetActiveSubroutineUniformiv.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static void
glGetActiveSubroutineName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query the subroutine name. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
IntBuffer
a variable which is to receive the length of the shader subroutine uniform name
length
,
ByteBuffer
an array into which the name of the shader subroutine uniform will be written
name
)

Queries the name of an active shader subroutine.

public static String
glGetActiveSubroutineName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query the subroutine name. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
int
the size of the buffer whose address is given in name
bufsize
)

Queries the name of an active shader subroutine.

public static String
glGetActiveSubroutineName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query the subroutine name. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
)

Queries the name of an active shader subroutine.

public static void
glGetActiveSubroutineName(int program, int shadertype, int index, int[] length, ByteBuffer name)

Array version of: GetActiveSubroutineName

public static int
glGetActiveSubroutineUniformi(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
int
the parameter of the shader subroutine uniform to query. One of:
NUM_COMPATIBLE_SUBROUTINESCOMPATIBLE_SUBROUTINESUNIFORM_SIZEUNIFORM_NAME_LENGTH
pname
)

Queries a property of an active shader subroutine uniform.

public static void
glGetActiveSubroutineUniformiv(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
int
the parameter of the shader subroutine uniform to query. One of:
NUM_COMPATIBLE_SUBROUTINESCOMPATIBLE_SUBROUTINESUNIFORM_SIZEUNIFORM_NAME_LENGTH
pname
,
IntBuffer
the address of a buffer into which the queried value or values will be placed
values
)

Queries a property of an active shader subroutine uniform.

public static void
glGetActiveSubroutineUniformiv(int program, int shadertype, int index, int pname, int[] values)

Array version of: GetActiveSubroutineUniformiv

public static void
glGetActiveSubroutineUniformName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
IntBuffer
the address of a variable into which is written the number of characters copied into name
length
,
ByteBuffer
the address of a buffer that will receive the name of the specified shader subroutine uniform
name
)

Queries the name of an active shader subroutine uniform.

public static String
glGetActiveSubroutineUniformName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
,
int
the size of the buffer whose address is given in name
bufsize
)

Queries the name of an active shader subroutine uniform.

public static String
glGetActiveSubroutineUniformName(int
the name of the program containing the subroutine
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the index of the shader subroutine uniform
index
)

Queries the name of an active shader subroutine uniform.

public static void
glGetActiveSubroutineUniformName(int program, int shadertype, int index, int[] length, ByteBuffer name)

Array version of: GetActiveSubroutineUniformName

public static int
glGetProgramStagei(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int pname)

Retrieves properties of a program object corresponding to a specified shader stage.

public static void
glGetProgramStageiv(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for the subroutine parameter. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int pname, IntBuffer
a variable into which the queried value or values will be placed
values
)

Retrieves properties of a program object corresponding to a specified shader stage.

public static void
glGetProgramStageiv(int program, int shadertype, int pname, int[] values)

Array version of: GetProgramStageiv

public static int
glGetSubroutineIndex(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for subroutine function index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
ByteBuffer
the name of the subroutine function whose index to query
name
)

Retrieves the index of a subroutine function of a given shader stage within a program.

public static int
glGetSubroutineIndex(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for subroutine function index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
CharSequence
the name of the subroutine function whose index to query
name
)

Retrieves the index of a subroutine function of a given shader stage within a program.

public static int
glGetSubroutineUniformLocation(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for subroutine uniform index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
ByteBuffer
the name of the subroutine uniform whose index to query.
name
)

Retrieves the location of a subroutine uniform of a given shader stage within a program.

public static int
glGetSubroutineUniformLocation(int
the name of the program containing shader stage
program
,
int
the shader stage from which to query for subroutine uniform index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
CharSequence
the name of the subroutine uniform whose index to query.
name
)

Retrieves the location of a subroutine uniform of a given shader stage within a program.

public static int
glGetUniformSubroutineui(int
the shader stage from which to query for subroutine uniform index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the location of the subroutine uniform
location
)

Retrieves the value of a subroutine uniform of a given shader stage of the current program.

public static void
glGetUniformSubroutineuiv(int
the shader stage from which to query for subroutine uniform index. One of:
VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
shadertype
,
int
the location of the subroutine uniform
location
,
IntBuffer
a variable to receive the value or values of the subroutine uniform
params
)

Retrieves the value of a subroutine uniform of a given shader stage of the current program.

public static void
glGetUniformSubroutineuiv(int shadertype, int location, int[] params)

Array version of: GetUniformSubroutineuiv

public static void
glUniformSubroutinesui(int shadertype, int index)

Loads active subroutine uniforms.

public static void
glUniformSubroutinesuiv(int shadertype, IntBuffer
an array holding the indices to load into the shader subroutine variables
indices
)

Loads active subroutine uniforms.

public static void
glUniformSubroutinesuiv(int shadertype, int[] indices)

Array version of: UniformSubroutinesuiv

public static void
nglGetActiveSubroutineName(int program, int shadertype, int index, int
the size of the buffer whose address is given in name
bufsize
,
long length, long name)

Unsafe version of: GetActiveSubroutineName

public static void
nglGetActiveSubroutineUniformiv(int program, int shadertype, int index, int pname, long values)

Unsafe version of: GetActiveSubroutineUniformiv

public static void
nglGetActiveSubroutineUniformName(int program, int shadertype, int index, int
the size of the buffer whose address is given in name
bufsize
,
long length, long name)

Unsafe version of: GetActiveSubroutineUniformName

public static void
nglGetProgramStageiv(int program, int shadertype, int pname, long values)

Unsafe version of: GetProgramStageiv

public static int
nglGetSubroutineIndex(int program, int shadertype, long name)

Unsafe version of: GetSubroutineIndex

public static int
nglGetSubroutineUniformLocation(int program, int shadertype, long name)

Unsafe version of: GetSubroutineUniformLocation

public static void
nglGetUniformSubroutineuiv(int shadertype, int location, long params)

Unsafe version of: GetUniformSubroutineuiv

public static void
nglUniformSubroutinesuiv(int shadertype, int
the number of uniform indices stored in indices
count
,
long indices)

Unsafe version of: UniformSubroutinesuiv

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

GL_ACTIVE_SUBROUTINE_MAX_LENGTHback to summary
public static final int GL_ACTIVE_SUBROUTINE_MAX_LENGTH

Accepted by the pname parameter of GetProgramStageiv.

GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONSback to summary
public static final int GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS

Accepted by the pname parameter of GetProgramStageiv.

GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTHback to summary
public static final int GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH

Accepted by the pname parameter of GetProgramStageiv.

GL_ACTIVE_SUBROUTINE_UNIFORMSback to summary
public static final int GL_ACTIVE_SUBROUTINE_UNIFORMS

Accepted by the pname parameter of GetProgramStageiv.

GL_ACTIVE_SUBROUTINESback to summary
public static final int GL_ACTIVE_SUBROUTINES

Accepted by the pname parameter of GetProgramStageiv.

GL_COMPATIBLE_SUBROUTINESback to summary
public static final int GL_COMPATIBLE_SUBROUTINES

Accepted by the pname parameter of GetActiveSubroutineUniformiv.

GL_MAX_SUBROUTINE_UNIFORM_LOCATIONSback to summary
public static final int GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetFloatv, GetDoublev, and GetInteger64v.

GL_MAX_SUBROUTINESback to summary
public static final int GL_MAX_SUBROUTINES

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetFloatv, GetDoublev, and GetInteger64v.

GL_NUM_COMPATIBLE_SUBROUTINESback to summary
public static final int GL_NUM_COMPATIBLE_SUBROUTINES

Accepted by the pname parameter of GetActiveSubroutineUniformiv.

Constructor Detail

ARBShaderSubroutineback to summary
protected ARBShaderSubroutine()

Method Detail

glGetActiveSubroutineNameback to summary
public static void glGetActiveSubroutineName(int program, int shadertype, int index, IntBuffer length, ByteBuffer name)

Queries the name of an active shader subroutine.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query the subroutine name. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

length:IntBuffer

a variable which is to receive the length of the shader subroutine uniform name

name:ByteBuffer

an array into which the name of the shader subroutine uniform will be written

glGetActiveSubroutineNameback to summary
public static String glGetActiveSubroutineName(int program, int shadertype, int index, int bufsize)

Queries the name of an active shader subroutine.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query the subroutine name. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

bufsize:int

the size of the buffer whose address is given in name

Annotations
@NativeType:void
glGetActiveSubroutineNameback to summary
public static String glGetActiveSubroutineName(int program, int shadertype, int index)

Queries the name of an active shader subroutine.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query the subroutine name. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

Annotations
@NativeType:void
glGetActiveSubroutineNameback to summary
public static void glGetActiveSubroutineName(int program, int shadertype, int index, int[] length, ByteBuffer name)

Array version of: GetActiveSubroutineName

glGetActiveSubroutineUniformiback to summary
public static int glGetActiveSubroutineUniformi(int program, int shadertype, int index, int pname)

Queries a property of an active shader subroutine uniform.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

pname:int

the parameter of the shader subroutine uniform to query. One of:

NUM_COMPATIBLE_SUBROUTINESCOMPATIBLE_SUBROUTINESUNIFORM_SIZEUNIFORM_NAME_LENGTH
Annotations
@NativeType:void
glGetActiveSubroutineUniformivback to summary
public static void glGetActiveSubroutineUniformiv(int program, int shadertype, int index, int pname, IntBuffer values)

Queries a property of an active shader subroutine uniform.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

pname:int

the parameter of the shader subroutine uniform to query. One of:

NUM_COMPATIBLE_SUBROUTINESCOMPATIBLE_SUBROUTINESUNIFORM_SIZEUNIFORM_NAME_LENGTH
values:IntBuffer

the address of a buffer into which the queried value or values will be placed

glGetActiveSubroutineUniformivback to summary
public static void glGetActiveSubroutineUniformiv(int program, int shadertype, int index, int pname, int[] values)

Array version of: GetActiveSubroutineUniformiv

glGetActiveSubroutineUniformNameback to summary
public static void glGetActiveSubroutineUniformName(int program, int shadertype, int index, IntBuffer length, ByteBuffer name)

Queries the name of an active shader subroutine uniform.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

length:IntBuffer

the address of a variable into which is written the number of characters copied into name

name:ByteBuffer

the address of a buffer that will receive the name of the specified shader subroutine uniform

glGetActiveSubroutineUniformNameback to summary
public static String glGetActiveSubroutineUniformName(int program, int shadertype, int index, int bufsize)

Queries the name of an active shader subroutine uniform.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

bufsize:int

the size of the buffer whose address is given in name

Annotations
@NativeType:void
glGetActiveSubroutineUniformNameback to summary
public static String glGetActiveSubroutineUniformName(int program, int shadertype, int index)

Queries the name of an active shader subroutine uniform.

Parameters
program:int

the name of the program containing the subroutine

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
index:int

the index of the shader subroutine uniform

Annotations
@NativeType:void
glGetActiveSubroutineUniformNameback to summary
public static void glGetActiveSubroutineUniformName(int program, int shadertype, int index, int[] length, ByteBuffer name)

Array version of: GetActiveSubroutineUniformName

glGetProgramStageiback to summary
public static int glGetProgramStagei(int program, int shadertype, int pname)

Retrieves properties of a program object corresponding to a specified shader stage.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
pname:int

the parameter of the shader to query. One of:

ACTIVE_SUBROUTINESACTIVE_SUBROUTINE_UNIFORMS
ACTIVE_SUBROUTINE_UNIFORM_LOCATIONSACTIVE_SUBROUTINE_MAX_LENGTH
ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH
Annotations
@NativeType:void
glGetProgramStageivback to summary
public static void glGetProgramStageiv(int program, int shadertype, int pname, IntBuffer values)

Retrieves properties of a program object corresponding to a specified shader stage.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for the subroutine parameter. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
pname:int

the parameter of the shader to query. One of:

ACTIVE_SUBROUTINESACTIVE_SUBROUTINE_UNIFORMS
ACTIVE_SUBROUTINE_UNIFORM_LOCATIONSACTIVE_SUBROUTINE_MAX_LENGTH
ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH
values:IntBuffer

a variable into which the queried value or values will be placed

glGetProgramStageivback to summary
public static void glGetProgramStageiv(int program, int shadertype, int pname, int[] values)

Array version of: GetProgramStageiv

glGetSubroutineIndexback to summary
public static int glGetSubroutineIndex(int program, int shadertype, ByteBuffer name)

Retrieves the index of a subroutine function of a given shader stage within a program.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for subroutine function index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
name:ByteBuffer

the name of the subroutine function whose index to query

Annotations
@NativeType:GLuint
glGetSubroutineIndexback to summary
public static int glGetSubroutineIndex(int program, int shadertype, CharSequence name)

Retrieves the index of a subroutine function of a given shader stage within a program.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for subroutine function index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
name:CharSequence

the name of the subroutine function whose index to query

Annotations
@NativeType:GLuint
glGetSubroutineUniformLocationback to summary
public static int glGetSubroutineUniformLocation(int program, int shadertype, ByteBuffer name)

Retrieves the location of a subroutine uniform of a given shader stage within a program.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for subroutine uniform index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
name:ByteBuffer

the name of the subroutine uniform whose index to query.

Annotations
@NativeType:GLint
glGetSubroutineUniformLocationback to summary
public static int glGetSubroutineUniformLocation(int program, int shadertype, CharSequence name)

Retrieves the location of a subroutine uniform of a given shader stage within a program.

Parameters
program:int

the name of the program containing shader stage

shadertype:int

the shader stage from which to query for subroutine uniform index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
name:CharSequence

the name of the subroutine uniform whose index to query.

Annotations
@NativeType:GLint
glGetUniformSubroutineuiback to summary
public static int glGetUniformSubroutineui(int shadertype, int location)

Retrieves the value of a subroutine uniform of a given shader stage of the current program.

Parameters
shadertype:int

the shader stage from which to query for subroutine uniform index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
location:int

the location of the subroutine uniform

Annotations
@NativeType:void
glGetUniformSubroutineuivback to summary
public static void glGetUniformSubroutineuiv(int shadertype, int location, IntBuffer params)

Retrieves the value of a subroutine uniform of a given shader stage of the current program.

Parameters
shadertype:int

the shader stage from which to query for subroutine uniform index. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
location:int

the location of the subroutine uniform

params:IntBuffer

a variable to receive the value or values of the subroutine uniform

glGetUniformSubroutineuivback to summary
public static void glGetUniformSubroutineuiv(int shadertype, int location, int[] params)

Array version of: GetUniformSubroutineuiv

glUniformSubroutinesuiback to summary
public static void glUniformSubroutinesui(int shadertype, int index)

Loads active subroutine uniforms.

Parameters
shadertype:int

the shader stage to update. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
glUniformSubroutinesuivback to summary
public static void glUniformSubroutinesuiv(int shadertype, IntBuffer indices)

Loads active subroutine uniforms.

Parameters
shadertype:int

the shader stage to update. One of:

VERTEX_SHADERFRAGMENT_SHADERGEOMETRY_SHADERTESS_CONTROL_SHADER
TESS_EVALUATION_SHADER
indices:IntBuffer

an array holding the indices to load into the shader subroutine variables

glUniformSubroutinesuivback to summary
public static void glUniformSubroutinesuiv(int shadertype, int[] indices)

Array version of: UniformSubroutinesuiv

nglGetActiveSubroutineNameback to summary
public static void nglGetActiveSubroutineName(int program, int shadertype, int index, int bufsize, long length, long name)

Unsafe version of: GetActiveSubroutineName

Parameters
bufsize:int

the size of the buffer whose address is given in name

nglGetActiveSubroutineUniformivback to summary
public static void nglGetActiveSubroutineUniformiv(int program, int shadertype, int index, int pname, long values)

Unsafe version of: GetActiveSubroutineUniformiv

nglGetActiveSubroutineUniformNameback to summary
public static void nglGetActiveSubroutineUniformName(int program, int shadertype, int index, int bufsize, long length, long name)

Unsafe version of: GetActiveSubroutineUniformName

Parameters
bufsize:int

the size of the buffer whose address is given in name

nglGetProgramStageivback to summary
public static void nglGetProgramStageiv(int program, int shadertype, int pname, long values)

Unsafe version of: GetProgramStageiv

nglGetSubroutineIndexback to summary
public static int nglGetSubroutineIndex(int program, int shadertype, long name)

Unsafe version of: GetSubroutineIndex

nglGetSubroutineUniformLocationback to summary
public static int nglGetSubroutineUniformLocation(int program, int shadertype, long name)

Unsafe version of: GetSubroutineUniformLocation

nglGetUniformSubroutineuivback to summary
public static void nglGetUniformSubroutineuiv(int shadertype, int location, long params)

Unsafe version of: GetUniformSubroutineuiv

nglUniformSubroutinesuivback to summary
public static void nglUniformSubroutinesuiv(int shadertype, int count, long indices)

Unsafe version of: UniformSubroutinesuiv

Parameters
count:int

the number of uniform indices stored in indices