Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2012-11-30 21:19:34 +0000
committerStijn Buys <ingar@osirion.org>2012-11-30 21:19:34 +0000
commit846700d05808157e43b7ae56b57a031d4b9c7a0d (patch)
tree33af4bb05cb9781cefce0a459e7ebb643aa0f73d /src/render
parenta7bd0a1b9abce66f9e918dd1c2def4abf0dd25c5 (diff)
Corrected a lighting bug while drawing fakespheres behind farplane.
Diffstat (limited to 'src/render')
-rw-r--r--src/render/lightenvironment.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/render/lightenvironment.cc b/src/render/lightenvironment.cc
index 1c61762..cacb80a 100644
--- a/src/render/lightenvironment.cc
+++ b/src/render/lightenvironment.cc
@@ -74,7 +74,7 @@ void LightEnvironment::draw(const math::Vector3f translate)
Light *light = (*it);
for (size_t i = 0; i < 3; i++) {
- gl_light_location[i] = light->location()[i];
+ gl_light_location[i] = light->location()[i] + translate[i];
gl_ambient_light[i] = light->color()[i] * env_ambient_intensity;
gl_diffuse_light[i] = light->color()[i] * env_diffuse_intensity;
gl_specular_light[i] = light->color()[i] * env_specular_intensity;