Class GlProgram
java.lang.Object
dev.engine_room.flywheel.backend.gl.GlObject
dev.engine_room.flywheel.backend.gl.shader.GlProgram
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbind()voidbindAttribLocation(String attribute, int binding) protected voiddeleteInternal(int handle) intgetUniformLocation(String uniform) Retrieves the index of the uniform with the given name.voidvoidvoidvoidvoidvoidsetSamplerBinding(String name, int binding) voidsetSamplerBinding(String name, GlTextureUnit binding) Binds a sampler uniform to the given texture unit.voidvoidsetUniformBlockBinding(String name, int binding) voidvoidvoidvoidstatic voidunbind()Methods inherited from class dev.engine_room.flywheel.backend.gl.GlObject
checkHandle, delete, handle, handle, invalidateHandle, isInvalid
-
Constructor Details
-
GlProgram
public GlProgram(int handle)
-
-
Method Details
-
bind
public void bind() -
unbind
public static void unbind() -
setFloat
-
setVec2
-
setVec3
-
setVec4
-
setMat4
-
setMat3
-
setBool
-
setUInt
-
setUVec2
-
setInt
-
getUniformLocation
Retrieves the index of the uniform with the given name.- Parameters:
uniform- The name of the uniform to find the index of- Returns:
- The uniform's index
-
setSamplerBinding
Binds a sampler uniform to the given texture unit.- Parameters:
name- The name of the sampler uniform.binding- The index of the texture unit.
-
setSamplerBinding
-
setUniformBlockBinding
-
bindAttribLocation
-
deleteInternal
protected void deleteInternal(int handle) - Specified by:
deleteInternalin classGlObject
-