33 lines
866 B
Java
33 lines
866 B
Java
package io.github.hydos.ginger.engine.renderEngine.shaders;
|
|
|
|
import io.github.hydos.ginger.engine.mathEngine.matrixes.Matrix4f;
|
|
|
|
public class GuiShader extends ShaderProgram{
|
|
|
|
private static final String VERTEX_FILE = "guiVertexShader.glsl";
|
|
private static final String FRAGMENT_FILE = "guiFragmentShader.glsl";
|
|
|
|
private int location_transformationMatrix;
|
|
|
|
public GuiShader() {
|
|
super(VERTEX_FILE, FRAGMENT_FILE);
|
|
}
|
|
|
|
public void loadTransformation(Matrix4f matrix){
|
|
super.loadMatrix(location_transformationMatrix, matrix);
|
|
}
|
|
|
|
@Override
|
|
protected void getAllUniformLocations() {
|
|
location_transformationMatrix = super.getUniformLocation("transformationMatrix");
|
|
}
|
|
|
|
@Override
|
|
protected void bindAttributes() {
|
|
super.bindAttribute(0, "position");
|
|
}
|
|
|
|
|
|
|
|
|
|
} |