summaryrefslogtreecommitdiff
path: root/indra/newview/llviewershadermgr.cpp
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2012-11-30 22:50:06 -0700
committerXiaohong Bao <bao@lindenlab.com>2012-11-30 22:50:06 -0700
commit21409a3aaaef71102195d65fc35cebdb5d941a26 (patch)
tree4b047d9c4e318fc25b242d3bd9c8cd706b9de661 /indra/newview/llviewershadermgr.cpp
parent6ae6abae26200c80a15d2e2d899ae6970602ff04 (diff)
for SH-3350 and SH-3353: Report frame-to-frame visual deltas as an LLStat
Diffstat (limited to 'indra/newview/llviewershadermgr.cpp')
-rw-r--r--indra/newview/llviewershadermgr.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/llviewershadermgr.cpp b/indra/newview/llviewershadermgr.cpp
index 5295573709..1aa36eafee 100644
--- a/indra/newview/llviewershadermgr.cpp
+++ b/indra/newview/llviewershadermgr.cpp
@@ -79,6 +79,7 @@ LLGLSLShader gSplatTextureRectProgram;
LLGLSLShader gGlowCombineFXAAProgram;
LLGLSLShader gTwoTextureAddProgram;
LLGLSLShader gTwoTextureCompareProgram;
+LLGLSLShader gOneTextureFilterProgram;
LLGLSLShader gOneTextureNoColorProgram;
LLGLSLShader gDebugProgram;
LLGLSLShader gClipProgram;
@@ -674,6 +675,7 @@ void LLViewerShaderMgr::unloadShaders()
gGlowCombineFXAAProgram.unload();
gTwoTextureAddProgram.unload();
gTwoTextureCompareProgram.unload();
+ gOneTextureFilterProgram.unload();
gOneTextureNoColorProgram.unload();
gSolidColorProgram.unload();
@@ -2726,6 +2728,21 @@ BOOL LLViewerShaderMgr::loadShadersInterface()
if (success)
{
+ gOneTextureFilterProgram.mName = "One Texture Filter Shader";
+ gOneTextureFilterProgram.mShaderFiles.clear();
+ gOneTextureFilterProgram.mShaderFiles.push_back(make_pair("interface/onetexturefilterV.glsl", GL_VERTEX_SHADER_ARB));
+ gOneTextureFilterProgram.mShaderFiles.push_back(make_pair("interface/onetexturefilterF.glsl", GL_FRAGMENT_SHADER_ARB));
+ gOneTextureFilterProgram.mShaderLevel = mVertexShaderLevel[SHADER_INTERFACE];
+ success = gOneTextureFilterProgram.createShader(NULL, NULL);
+ if (success)
+ {
+ gOneTextureFilterProgram.bind();
+ gOneTextureFilterProgram.uniform1i("tex0", 0);
+ }
+ }
+
+ if (success)
+ {
gOneTextureNoColorProgram.mName = "One Texture No Color Shader";
gOneTextureNoColorProgram.mShaderFiles.clear();
gOneTextureNoColorProgram.mShaderFiles.push_back(make_pair("interface/onetexturenocolorV.glsl", GL_VERTEX_SHADER_ARB));