mirror of
https://github.com/JoeyDeVries/LearnOpenGL.git
synced 2026-01-30 20:13:22 +08:00
Fixed stencil testing sample to actually set the uniform matrices on the single color shader program. Without it, the border does not show up.
This commit is contained in:
@@ -195,8 +195,8 @@ int main()
|
||||
glm::mat4 model;
|
||||
glm::mat4 view = camera.GetViewMatrix();
|
||||
glm::mat4 projection = glm::perspective(camera.Zoom, (float)SCR_WIDTH / (float)SCR_HEIGHT, 0.1f, 100.0f);
|
||||
shader.setMat4("view", view);
|
||||
shader.setMat4("projection", projection);
|
||||
shaderSingleColor.setMat4("view", view);
|
||||
shaderSingleColor.setMat4("projection", projection);
|
||||
|
||||
shader.use();
|
||||
shader.setMat4("view", view);
|
||||
|
||||
Reference in New Issue
Block a user