X-Git-Url: http://git.localhorst.tv/?p=blobs.git;a=blobdiff_plain;f=src%2Fapp%2Fstates.cpp;h=68c66f2f3d29d6c3ac9c35cf1f83206d30646d03;hp=5e3642b6bb4433cd7073df99daa22c9f163641d9;hb=91c987450eb7595ff2ef68c925f945ca89d4d879;hpb=c8f8dc657e7321aff362a3c88862388ef2fb1b20 diff --git a/src/app/states.cpp b/src/app/states.cpp index 5e3642b..68c66f2 100644 --- a/src/app/states.cpp +++ b/src/app/states.cpp @@ -190,9 +190,9 @@ void MasterState::OnRender(graphics::Viewport &viewport) { // TODO: source sun's light color and strength glm::vec3 pos(cam.View() * cam.Model(*sun)[3]); assets.shaders.planet_surface.Activate(); - assets.shaders.planet_surface.SetLight(num_lights, pos, sun->Color(), sun->Luminosity()); + assets.shaders.planet_surface.SetLight(num_lights, pos, glm::vec3(sun->Color()), float(sun->Luminosity())); assets.shaders.creature_skin.Activate(); - assets.shaders.creature_skin.SetLight(num_lights, pos, sun->Color(), sun->Luminosity()); + assets.shaders.creature_skin.SetLight(num_lights, pos, glm::vec3(sun->Color()), float(sun->Luminosity())); ++num_lights; if (num_lights >= graphics::PlanetSurface::MAX_LIGHTS || num_lights >= graphics::CreatureSkin::MAX_LIGHTS) { break;