diff options
author | Stijn Buys <ingar@osirion.org> | 2012-11-30 21:19:34 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2012-11-30 21:19:34 +0000 |
commit | 846700d05808157e43b7ae56b57a031d4b9c7a0d (patch) | |
tree | 33af4bb05cb9781cefce0a459e7ebb643aa0f73d | |
parent | a7bd0a1b9abce66f9e918dd1c2def4abf0dd25c5 (diff) |
Corrected a lighting bug while drawing fakespheres behind farplane.
-rw-r--r-- | src/render/lightenvironment.cc | 2 |
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; |