summaryrefslogtreecommitdiff
path: root/indra/newview/llvosky.cpp
diff options
context:
space:
mode:
authorTofu Linden <tofu.linden@lindenlab.com>2010-08-24 14:52:05 +0100
committerTofu Linden <tofu.linden@lindenlab.com>2010-08-24 14:52:05 +0100
commitce1a0c6bafad092f9687e3b5a6b4865569d96863 (patch)
tree29dafcce870eb2f494bebe2d968721abe266e930 /indra/newview/llvosky.cpp
parentd179727469692054fc100a9f1d68f181bebcd7de (diff)
parent308d9f10147ff31752c90150bc3ee769a63837e9 (diff)
Final(???) merge from viewer-release to viewer-public.
Diffstat (limited to 'indra/newview/llvosky.cpp')
-rw-r--r--indra/newview/llvosky.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/indra/newview/llvosky.cpp b/indra/newview/llvosky.cpp
index d73850cb49..bb80988854 100644
--- a/indra/newview/llvosky.cpp
+++ b/indra/newview/llvosky.cpp
@@ -975,7 +975,10 @@ void LLVOSky::calcAtmospherics(void)
}
temp2.mV[1] = llmax(0.f, lighty);
- temp2.mV[1] = 1.f / temp2.mV[1];
+ if(temp2.mV[1] > 0.f)
+ {
+ temp2.mV[1] = 1.f / temp2.mV[1];
+ }
componentMultBy(sunlight, componentExp((light_atten * -1.f) * temp2.mV[1]));
// Distance