summaryrefslogtreecommitdiff
path: root/indra/newview/llviewershadermgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llviewershadermgr.cpp')
-rw-r--r--indra/newview/llviewershadermgr.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/indra/newview/llviewershadermgr.cpp b/indra/newview/llviewershadermgr.cpp
index 5d3da55499..b866cedaaa 100644
--- a/indra/newview/llviewershadermgr.cpp
+++ b/indra/newview/llviewershadermgr.cpp
@@ -653,6 +653,7 @@ std::string LLViewerShaderMgr::loadBasicShaders()
shaders.push_back( make_pair( "environment/srgbF.glsl", 1 ) );
shaders.push_back( make_pair( "avatar/avatarSkinV.glsl", 1 ) );
shaders.push_back( make_pair( "avatar/objectSkinV.glsl", 1 ) );
+ shaders.push_back( make_pair( "deferred/textureUtilV.glsl", 1 ) );
if (gGLManager.mGLSLVersionMajor >= 2 || gGLManager.mGLSLVersionMinor >= 30)
{
shaders.push_back( make_pair( "objects/indexedTextureV.glsl", 1 ) );
@@ -1319,6 +1320,11 @@ BOOL LLViewerShaderMgr::loadShadersDeferred()
gDeferredPBROpaqueProgram.mShaderFiles.push_back(make_pair("deferred/pbropaqueV.glsl", GL_VERTEX_SHADER));
gDeferredPBROpaqueProgram.mShaderFiles.push_back(make_pair("deferred/pbropaqueF.glsl", GL_FRAGMENT_SHADER));
gDeferredPBROpaqueProgram.mShaderLevel = mShaderLevel[SHADER_DEFERRED];
+ gDeferredPBROpaqueProgram.clearPermutations();
+ if (gSavedSettings.getBOOL("RenderDebugTexcoord"))
+ {
+ gDeferredPBROpaqueProgram.addPermutation("DEBUG_TEXCOORD", "1");
+ }
success = make_rigged_variant(gDeferredPBROpaqueProgram, gDeferredSkinnedPBROpaqueProgram);
if (success)
@@ -1355,6 +1361,10 @@ BOOL LLViewerShaderMgr::loadShadersDeferred()
gHUDPBROpaqueProgram.mShaderLevel = mShaderLevel[SHADER_DEFERRED];
gHUDPBROpaqueProgram.clearPermutations();
gHUDPBROpaqueProgram.addPermutation("IS_HUD", "1");
+ if (gSavedSettings.getBOOL("RenderDebugTexcoord"))
+ {
+ gHUDPBROpaqueProgram.addPermutation("DEBUG_TEXCOORD", "1");
+ }
success = gHUDPBROpaqueProgram.createShader(NULL, NULL);
@@ -1398,6 +1408,10 @@ BOOL LLViewerShaderMgr::loadShadersDeferred()
{
shader->addPermutation("HAS_SUN_SHADOW", "1");
}
+ if (gSavedSettings.getBOOL("RenderDebugTexcoord"))
+ {
+ shader->addPermutation("DEBUG_TEXCOORD", "1");
+ }
shader->mShaderLevel = mShaderLevel[SHADER_DEFERRED];
success = make_rigged_variant(*shader, gDeferredSkinnedPBRAlphaProgram);
@@ -1430,6 +1444,10 @@ BOOL LLViewerShaderMgr::loadShadersDeferred()
shader->clearPermutations();
shader->addPermutation("IS_HUD", "1");
+ if (gSavedSettings.getBOOL("RenderDebugTexcoord"))
+ {
+ shader->addPermutation("DEBUG_TEXCOORD", "1");
+ }
shader->mShaderLevel = mShaderLevel[SHADER_DEFERRED];
success = shader->createShader(NULL, NULL);