diff options
author | Dave Parks <davep@lindenlab.com> | 2012-01-24 12:59:18 -0600 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2012-01-24 12:59:18 -0600 |
commit | e02f007d2013e089c07f3abefe2d87d85cbcc834 (patch) | |
tree | e5d1342952d33265ce12ebeea4fb4bed8a0c1377 /indra/newview/pipeline.cpp | |
parent | 18e7f1bffd875bb933212367f0d62dfc4da871b9 (diff) |
SH-1427 Fix for spot lights not working properly on alpha objects, and fix for alpha lighting of point lights not matching deferred lights.
Diffstat (limited to 'indra/newview/pipeline.cpp')
-rw-r--r-- | indra/newview/pipeline.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index df8f8793d1..38f9851929 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -5297,7 +5297,8 @@ void LLPipeline::setupHWLights(LLDrawPool* pool) light_state->setConstantAttenuation(0.f); if (sRenderDeferred) { - light_state->setLinearAttenuation(light_radius*1.5f); + F32 size = light_radius*1.5f; + light_state->setLinearAttenuation(size*size); light_state->setQuadraticAttenuation(light->getLightFalloff()*0.5f+1.f); } else @@ -5319,7 +5320,8 @@ void LLPipeline::setupHWLights(LLDrawPool* pool) light_state->setSpotCutoff(90.f); light_state->setSpotExponent(2.f); - light_state->setSpecular(LLColor4::black); + const LLColor4 specular(0.f, 0.f, 0.f, 0.f); + light_state->setSpecular(specular); } else // omnidirectional (point) light { |