summaryrefslogtreecommitdiff
path: root/indra/newview/llscenemonitor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llscenemonitor.cpp')
-rw-r--r--indra/newview/llscenemonitor.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/indra/newview/llscenemonitor.cpp b/indra/newview/llscenemonitor.cpp
index db2936b1fd..142cda87a4 100644
--- a/indra/newview/llscenemonitor.cpp
+++ b/indra/newview/llscenemonitor.cpp
@@ -334,6 +334,10 @@ bool LLSceneMonitor::needsUpdate() const
static LLTrace::TimeBlock FTM_GENERATE_SCENE_LOAD_DITHER_TEXTURE("Generate Scene Load Dither Texture");
static LLTrace::TimeBlock FTM_SCENE_LOAD_IMAGE_DIFF("Scene Load Image Diff");
+static LLStaticHashedString sDitherScale("dither_scale");
+static LLStaticHashedString sDitherScaleS("dither_scale_s");
+static LLStaticHashedString sDitherScaleT("dither_scale_t");
+
void LLSceneMonitor::compare()
{
if(mDiffState != NEED_DIFF)
@@ -375,9 +379,9 @@ void LLSceneMonitor::compare()
gTwoTextureCompareProgram.bind();
- gTwoTextureCompareProgram.uniform1f("dither_scale", mDitherScale);
- gTwoTextureCompareProgram.uniform1f("dither_scale_s", mDitherScaleS);
- gTwoTextureCompareProgram.uniform1f("dither_scale_t", mDitherScaleT);
+ gTwoTextureCompareProgram.uniform1f(sDitherScale, mDitherScale);
+ gTwoTextureCompareProgram.uniform1f(sDitherScaleS, mDitherScaleS);
+ gTwoTextureCompareProgram.uniform1f(sDitherScaleT, mDitherScaleT);
gGL.getTexUnit(0)->activate();
gGL.getTexUnit(0)->enable(LLTexUnit::TT_TEXTURE);
@@ -413,6 +417,8 @@ void LLSceneMonitor::compare()
}
}
+static LLStaticHashedString sTolerance("tolerance");
+
//calculate Diff aggregate information in GPU, and enable gl occlusion query to capture it.
void LLSceneMonitor::calcDiffAggregate()
{
@@ -438,7 +444,7 @@ void LLSceneMonitor::calcDiffAggregate()
cur_shader = LLGLSLShader::sCurBoundShaderPtr;
gOneTextureFilterProgram.bind();
- gOneTextureFilterProgram.uniform1f("tolerance", mDiffTolerance);
+ gOneTextureFilterProgram.uniform1f(sTolerance, mDiffTolerance);
if(mDiffState == EXECUTE_DIFF)
{