From 2a09c7f83c77927f086e05dda6bc7e301d96fe91 Mon Sep 17 00:00:00 2001 From: Faerbit Date: Mon, 1 Jun 2015 13:35:23 +0200 Subject: [PATCH] Fixing wrong shader getting used. --- game/graphics.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/game/graphics.cc b/game/graphics.cc index 517afd8..d484c13 100644 --- a/game/graphics.cc +++ b/game/graphics.cc @@ -340,6 +340,7 @@ void Graphics::render(double time) if (renderShadows) { // render depth textures for point lights glViewport(0, 0, cube_size, cube_size); + depthCubeShader->use(); glm::mat4 depthProjectionMatrix_pointlights = glm::perspective(1.571f, (float)cube_size/(float)cube_size, 0.1f, 50.0f); glm::vec3 looking_directions[6] = {glm::vec3(1.0f, 0.0f, 0.0f), glm::vec3(-1.0f, 0.0f, 0.0f), glm::vec3(0.0f, 1.0f, 0.0f), glm::vec3(0.0f, -1.0f, 0.0f), glm::vec3(0.0f, 0.0f, 1.0f), glm::vec3(0.0f, 0.0f, -1.0f)};