diff options
author | Dave Parks <davep@lindenlab.com> | 2010-05-01 01:55:21 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2010-05-01 01:55:21 -0500 |
commit | 2f95a549a365ca2bedf7824014a687b3af88e20f (patch) | |
tree | 26d87b108ffd4730d29ae9ebed2f34154c904e86 /indra/newview/llviewershadermgr.cpp | |
parent | ad8fb0e1bb6c242cc84aa3d2cfaabc9ee36e39b6 (diff) |
Fullbrigt skinned and fix for silly crash from not removing face references.
Diffstat (limited to 'indra/newview/llviewershadermgr.cpp')
-rw-r--r-- | indra/newview/llviewershadermgr.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/newview/llviewershadermgr.cpp b/indra/newview/llviewershadermgr.cpp index fe68d6eaa4..3cc5b4357a 100644 --- a/indra/newview/llviewershadermgr.cpp +++ b/indra/newview/llviewershadermgr.cpp @@ -79,6 +79,7 @@ LLGLSLShader gObjectShinyWaterProgram; //object hardware skinning shaders LLGLSLShader gSkinnedObjectSimpleProgram; +LLGLSLShader gSkinnedObjectFullbrightProgram; LLGLSLShader gSkinnedObjectShinySimpleProgram; //environment shaders @@ -155,6 +156,7 @@ LLViewerShaderMgr::LLViewerShaderMgr() : mShaderList.push_back(&gObjectFullbrightProgram); mShaderList.push_back(&gObjectFullbrightShinyProgram); mShaderList.push_back(&gSkinnedObjectSimpleProgram); + mShaderList.push_back(&gSkinnedObjectFullbrightProgram); mShaderList.push_back(&gSkinnedObjectShinySimpleProgram); mShaderList.push_back(&gTerrainProgram); mShaderList.push_back(&gTerrainWaterProgram); @@ -562,6 +564,7 @@ void LLViewerShaderMgr::unloadShaders() gObjectShinyWaterProgram.unload(); gSkinnedObjectSimpleProgram.unload(); + gSkinnedObjectFullbrightProgram.unload(); gSkinnedObjectShinySimpleProgram.unload(); @@ -1258,6 +1261,7 @@ BOOL LLViewerShaderMgr::loadShadersObject() gObjectFullbrightProgram.unload(); gObjectFullbrightWaterProgram.unload(); gSkinnedObjectSimpleProgram.unload(); + gSkinnedObjectFullbrightProgram.unload(); gSkinnedObjectShinySimpleProgram.unload(); return FALSE; @@ -1387,6 +1391,21 @@ BOOL LLViewerShaderMgr::loadShadersObject() if (success) { + gSkinnedObjectFullbrightProgram.mName = "Skinned Fullbright Shader"; + gSkinnedObjectFullbrightProgram.mFeatures.calculatesAtmospherics = true; + gSkinnedObjectFullbrightProgram.mFeatures.hasGamma = true; + gSkinnedObjectFullbrightProgram.mFeatures.hasTransport = true; + gSkinnedObjectFullbrightProgram.mFeatures.isFullbright = true; + gSkinnedObjectFullbrightProgram.mFeatures.hasObjectSkinning = true; + gSkinnedObjectFullbrightProgram.mShaderFiles.clear(); + gSkinnedObjectFullbrightProgram.mShaderFiles.push_back(make_pair("objects/fullbrightSkinnedV.glsl", GL_VERTEX_SHADER_ARB)); + gSkinnedObjectFullbrightProgram.mShaderFiles.push_back(make_pair("objects/fullbrightF.glsl", GL_FRAGMENT_SHADER_ARB)); + gSkinnedObjectFullbrightProgram.mShaderLevel = mVertexShaderLevel[SHADER_OBJECT]; + success = gSkinnedObjectFullbrightProgram.createShader(NULL, NULL); + } + + if (success) + { gSkinnedObjectShinySimpleProgram.mName = "Skinned Shiny Simple Shader"; gSkinnedObjectShinySimpleProgram.mFeatures.calculatesLighting = true; gSkinnedObjectShinySimpleProgram.mFeatures.calculatesAtmospherics = true; |