summaryrefslogtreecommitdiff
path: root/indra/newview/llvosky.cpp
diff options
context:
space:
mode:
authorprep <none@none>2012-03-13 15:48:24 -0400
committerprep <none@none>2012-03-13 15:48:24 -0400
commitfab57eea612f34ed9d8c8559674ead1760aab42b (patch)
tree51394d44e1b89bb75d168464aec539f60f44f8cd /indra/newview/llvosky.cpp
parent87b414c4934d0d52eef0b323245568bb1e95ec70 (diff)
parent00717147d2b832fa3239267edf409f0a1dfcd9fd (diff)
pull and merge from viewer-development
Diffstat (limited to 'indra/newview/llvosky.cpp')
-rw-r--r--indra/newview/llvosky.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/indra/newview/llvosky.cpp b/indra/newview/llvosky.cpp
index e9db37821b..312034022e 100644
--- a/indra/newview/llvosky.cpp
+++ b/indra/newview/llvosky.cpp
@@ -342,7 +342,7 @@ LLVOSky::LLVOSky(const LLUUID &id, const LLPCode pcode, LLViewerRegion *regionp)
blue_density = LLColor3();
blue_horizon = LLColor3();
haze_density = 0.f;
- haze_horizon = LLColor3();
+ haze_horizon = 1.f;
density_multiplier = 0.f;
max_y = 0.f;
glow = LLColor3();
@@ -651,17 +651,17 @@ void LLVOSky::initAtmospherics(void)
sunlight_color = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("sunlight_color", error));
ambient = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("ambient", error));
//lightnorm = LLWLParamManager::getInstance()->mCurParams.getVector("lightnorm", error);
- gamma = LLWLParamManager::getInstance()->mCurParams.getVector("gamma", error)[0];
+ gamma = LLWLParamManager::getInstance()->mCurParams.getFloat("gamma", error);
blue_density = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("blue_density", error));
blue_horizon = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("blue_horizon", error));
- haze_density = LLWLParamManager::getInstance()->mCurParams.getVector("haze_density", error)[0];
- haze_horizon = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("haze_horizon", error));
- density_multiplier = LLWLParamManager::getInstance()->mCurParams.getVector("density_multiplier", error)[0];
- max_y = LLWLParamManager::getInstance()->mCurParams.getVector("max_y", error)[0];
+ haze_density = LLWLParamManager::getInstance()->mCurParams.getFloat("haze_density", error);
+ haze_horizon = LLWLParamManager::getInstance()->mCurParams.getFloat("haze_horizon", error);
+ density_multiplier = LLWLParamManager::getInstance()->mCurParams.getFloat("density_multiplier", error);
+ max_y = LLWLParamManager::getInstance()->mCurParams.getFloat("max_y", error);
glow = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("glow", error));
- cloud_shadow = LLWLParamManager::getInstance()->mCurParams.getVector("cloud_shadow", error)[0];
+ cloud_shadow = LLWLParamManager::getInstance()->mCurParams.getFloat("cloud_shadow", error);
cloud_color = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("cloud_color", error));
- cloud_scale = LLWLParamManager::getInstance()->mCurParams.getVector("cloud_scale", error)[0];
+ cloud_scale = LLWLParamManager::getInstance()->mCurParams.getFloat("cloud_scale", error);
cloud_pos_density1 = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("cloud_pos_density1", error));
cloud_pos_density2 = LLColor3(LLWLParamManager::getInstance()->mCurParams.getVector("cloud_pos_density2", error));
@@ -825,7 +825,7 @@ void LLVOSky::calcSkyColorWLVert(LLVector3 & Pn, LLColor3 & vary_HazeColor, LLCo
// Haze color above cloud
vary_HazeColor = (blue_horizon * blue_weight * (sunlight + ambient)
- + componentMult(haze_horizon.mV[0] * haze_weight, sunlight * temp2.mV[0] + ambient)
+ + componentMult(haze_horizon * haze_weight, sunlight * temp2.mV[0] + ambient)
);
// Increase ambient when there are more clouds
@@ -836,7 +836,7 @@ void LLVOSky::calcSkyColorWLVert(LLVector3 & Pn, LLColor3 & vary_HazeColor, LLCo
// Haze color below cloud
LLColor3 additiveColorBelowCloud = (blue_horizon * blue_weight * (sunlight + tmpAmbient)
- + componentMult(haze_horizon.mV[0] * haze_weight, sunlight * temp2.mV[0] + tmpAmbient)
+ + componentMult(haze_horizon * haze_weight, sunlight * temp2.mV[0] + tmpAmbient)
);
// Final atmosphere additive
@@ -1002,7 +1002,7 @@ void LLVOSky::calcAtmospherics(void)
//haze color
vary_HazeColor =
(blue_horizon * blue_weight * (sunlight*(1.f - cloud_shadow) + tmpAmbient)
- + componentMult(haze_horizon.mV[0] * haze_weight, sunlight*(1.f - cloud_shadow) * temp2.mV[0] + tmpAmbient)
+ + componentMult(haze_horizon * haze_weight, sunlight*(1.f - cloud_shadow) * temp2.mV[0] + tmpAmbient)
);
//brightness of surface both sunlight and ambient