Use LLStaticHashedString for faster uniform lookup.

This commit is contained in:
Shyotl
2013-10-26 16:26:46 -05:00
parent 8e94c43a54
commit 8441bc80a4
20 changed files with 579 additions and 322 deletions

View File

@@ -373,8 +373,8 @@ void LLWLParamManager::updateShaderUniforms(LLGLSLShader * shader)
if (shader->mShaderGroup == LLGLSLShader::SG_DEFAULT)
{
shader->uniform4fv(LLViewerShaderMgr::LIGHTNORM, 1, mRotatedLightDir.mV);
shader->uniform3fv("camPosLocal", 1, LLViewerCamera::getInstance()->getOrigin().mV);
shader->uniform4fv(LLShaderMgr::LIGHTNORM, 1, mRotatedLightDir.mV);
shader->uniform3fv(LLShaderMgr::WL_CAMPOSLOCAL, 1, LLViewerCamera::getInstance()->getOrigin().mV);
}
else if (shader->mShaderGroup == LLGLSLShader::SG_SKY)
@@ -382,7 +382,7 @@ void LLWLParamManager::updateShaderUniforms(LLGLSLShader * shader)
shader->uniform4fv(LLViewerShaderMgr::LIGHTNORM, 1, mClampedLightDir.mV);
}
shader->uniform1f("scene_light_strength", mSceneLightStrength);
shader->uniform1f(LLShaderMgr::SCENE_LIGHT_STRENGTH, mSceneLightStrength);
}