diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp index d84158342..4490f87be 100644 --- a/indra/llrender/llglslshader.cpp +++ b/indra/llrender/llglslshader.cpp @@ -133,7 +133,8 @@ BOOL LLGLSLShader::createShader(vector * attributes, mProgramObject = glCreateProgramObjectARB(); static const LLCachedControl no_texture_indexing("ShyotlUseLegacyTextureBatching",false); - if (gGLManager.mGLVersion < 3.1f || no_texture_indexing) + static const LLCachedControl use_legacy_path("ShyotlUseLegacyRenderPath", false); //Legacy does not jive with new batching. + if (gGLManager.mGLVersion < 3.1f || no_texture_indexing || use_legacy_path) { //force indexed texture channels to 1 if GL version is old (performance improvement for drivers with poor branching shader model support) mFeatures.mIndexedTextureChannels = llmin(mFeatures.mIndexedTextureChannels, 1); } diff --git a/indra/newview/llviewershadermgr.cpp b/indra/newview/llviewershadermgr.cpp index f7f860385..f4a84fb2a 100644 --- a/indra/newview/llviewershadermgr.cpp +++ b/indra/newview/llviewershadermgr.cpp @@ -655,7 +655,8 @@ BOOL LLViewerShaderMgr::loadBasicShaders() S32 ch = gGLManager.mNumTextureImageUnits-1; static const LLCachedControl no_texture_indexing("ShyotlUseLegacyTextureBatching",false); - if (gGLManager.mGLVersion < 3.1f || no_texture_indexing) + static const LLCachedControl use_legacy_path("ShyotlUseLegacyRenderPath", false); //Legacy does not jive with new batching. + if (gGLManager.mGLVersion < 3.1f || no_texture_indexing || use_legacy_path) { //force to 1 texture index channel for old drivers ch = 1; } diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 9029a8188..f07c9c37d 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -3927,7 +3927,8 @@ void LLVolumeGeometryManager::genDrawInfo(LLSpatialGroup* group, U32 mask, std:: S32 texture_index_channels = gGLManager.mNumTextureImageUnits-1; //always reserve one for shiny for now just for simplicity static const LLCachedControl no_texture_indexing("ShyotlUseLegacyTextureBatching",false); - if (gGLManager.mGLVersion < 3.1f || no_texture_indexing) + static const LLCachedControl use_legacy_path("ShyotlUseLegacyRenderPath", false); //Legacy does not jive with new batching. + if (gGLManager.mGLVersion < 3.1f || no_texture_indexing || use_legacy_path) { texture_index_channels = 1; }