Skip to content

Commit

Permalink
load correct shader
Browse files Browse the repository at this point in the history
  • Loading branch information
i-make-robots committed Dec 20, 2023
1 parent 484e323 commit 02668c2
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -383,13 +383,13 @@ public void keyReleased(KeyEvent e) {

private void createShaderPrograms(GL3 gl3) {
shaderDefault = new ShaderProgram(gl3,
readResource("mesh.vert"),
readResource("mesh.frag"));
readResource("default_330.vert"),
readResource("default_330.frag"));
shaderOutline = new ShaderProgram(gl3,
readResource("outline_330.vert"),
readResource("outline_330.frag"));
shaderHUD = new ShaderProgram(gl3,
readResource("mesh.vert"),
readResource("default_330.vert"),
readResource("givenColor_330.frag"));
}

Expand Down Expand Up @@ -720,6 +720,7 @@ private void renderOneMMRItem(GL3 gl, MatrixMaterialRender mmr, ShaderProgram sh
// if we have a texture assigned, then we might still enable textures.
texture = material.texture.getTexture();
if(texture==null) useTexture = false;

// assign the object's overall color.
double[] diffuseColor = material.getDiffuseColor();
shaderProgram.set4f(gl,
Expand Down

0 comments on commit 02668c2

Please sign in to comment.