Skip to content

Commit

Permalink
Update shaders_mesh_instancing.c
Browse files Browse the repository at this point in the history
adding a missing  'locs[SHADER_LOC_MATRIX_MODEL] = GetShaderLocationAttrib(shader, "instanceTransform");'
  • Loading branch information
MikiZX1 authored Jan 14, 2025
1 parent cfbba79 commit 21b5383
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/shaders/shaders_mesh_instancing.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ int main(void)
// Get shader locations
shader.locs[SHADER_LOC_MATRIX_MVP] = GetShaderLocation(shader, "mvp");
shader.locs[SHADER_LOC_VECTOR_VIEW] = GetShaderLocation(shader, "viewPos");

shader.locs[SHADER_LOC_MATRIX_MODEL] = GetShaderLocationAttrib(shader, "instanceTransform");

// Set shader value: ambient light level
int ambientLoc = GetShaderLocation(shader, "ambient");
SetShaderValue(shader, ambientLoc, (float[4]){ 0.2f, 0.2f, 0.2f, 1.0f }, SHADER_UNIFORM_VEC4);
Expand Down

0 comments on commit 21b5383

Please sign in to comment.