summaryrefslogtreecommitdiff
path: root/indra/newview/llwlparamset.cpp
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2012-02-10 12:06:01 -0500
committerNat Goodspeed <nat@lindenlab.com>2012-02-10 12:06:01 -0500
commit4849173fd87ff9199a0fee86dc6a43afe3936e71 (patch)
tree7d765b6d9aeba3ba0388ac229a8f63aa7a4af607 /indra/newview/llwlparamset.cpp
parent028a05e79467e0c1fd7d63224fb447a964ab7a0b (diff)
parent58348bd862163261fb650d8afd50fd1dc5e2695a (diff)
Merge daggy fix in rev a05866ebfea2 (Linux lib wildcards)
Diffstat (limited to 'indra/newview/llwlparamset.cpp')
-rw-r--r--indra/newview/llwlparamset.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/indra/newview/llwlparamset.cpp b/indra/newview/llwlparamset.cpp
index 02d914a812..5bb7025031 100644
--- a/indra/newview/llwlparamset.cpp
+++ b/indra/newview/llwlparamset.cpp
@@ -69,12 +69,18 @@ LLWLParamSet::LLWLParamSet(void) :
*/
}
+static LLFastTimer::DeclareTimer FTM_WL_PARAM_UPDATE("WL Param Update");
+
void LLWLParamSet::update(LLGLSLShader * shader) const
{
+ LLFastTimer t(FTM_WL_PARAM_UPDATE);
+
for(LLSD::map_const_iterator i = mParamValues.beginMap();
i != mParamValues.endMap();
++i)
{
+
+
const std::string& param = i->first;
if( param == "star_brightness" || param == "preset_num" || param == "sun_angle" ||
@@ -91,8 +97,9 @@ void LLWLParamSet::update(LLGLSLShader * shader) const
val.mV[1] = F32(i->second[1].asReal()) + mCloudScrollYOffset;
val.mV[2] = (F32) i->second[2].asReal();
val.mV[3] = (F32) i->second[3].asReal();
-
- shader->uniform4fv(param, 1, val.mV);
+ stop_glerror();
+ shader->uniform4fv(param, 1, val.mV);
+ stop_glerror();
}
else // param is the uniform name
{
@@ -118,8 +125,9 @@ void LLWLParamSet::update(LLGLSLShader * shader) const
{
val.mV[0] = i->second.asBoolean();
}
-
+ stop_glerror();
shader->uniform4fv(param, 1, val.mV);
+ stop_glerror();
}
}
}