From 9448db5d4af7bba094e5bc51f85e5c2491d3f5a1 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Thu, 6 Oct 2022 18:40:01 -0500 Subject: SL-18190 Water shader WIP. Better parallax correction for sphere probes. Reduce probe memory footprint. Remove framebuffer copies and move to deprecate stencil buffer usage. --- indra/newview/lldrawpoolmaterials.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 2b05f4c453..d97f0714ef 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -260,7 +260,7 @@ void LLDrawPoolMaterials::pushMaterialsBatch(LLDrawInfo& params, U32 mask, bool (GLfloat*)&(mpc.mGLMp[0])); } - LLGLEnableFunc stencil_test(GL_STENCIL_TEST, params.mSelected, &LLGLCommonFunc::selected_stencil_test); + //LLGLEnableFunc stencil_test(GL_STENCIL_TEST, params.mSelected, &LLGLCommonFunc::selected_stencil_test); params.mVertexBuffer->setBufferFast(mask); params.mVertexBuffer->drawRangeFast(params.mDrawMode, params.mStart, params.mEnd, params.mCount, params.mOffset); -- cgit v1.2.3 From 8d2ac419b22c8c9475f2efb312dd198ac8eb9fb7 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Wed, 16 Nov 2022 14:49:17 -0600 Subject: SL-18154 Profile guided optimizations vs release viewer. Trim some unused abilities and remove some more fast timers. --- indra/newview/lldrawpoolmaterials.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index d97f0714ef..1c9fb55d06 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -263,7 +263,7 @@ void LLDrawPoolMaterials::pushMaterialsBatch(LLDrawInfo& params, U32 mask, bool //LLGLEnableFunc stencil_test(GL_STENCIL_TEST, params.mSelected, &LLGLCommonFunc::selected_stencil_test); params.mVertexBuffer->setBufferFast(mask); - params.mVertexBuffer->drawRangeFast(params.mDrawMode, params.mStart, params.mEnd, params.mCount, params.mOffset); + params.mVertexBuffer->drawRangeFast(LLRender::TRIANGLES, params.mStart, params.mEnd, params.mCount, params.mOffset); if (tex_setup) { -- cgit v1.2.3 From e2d1af5c4f7bdc04becb4a4fd56b7e9057bdfedc Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Thu, 17 Nov 2022 13:35:39 -0600 Subject: SL-18154 Profile guided optimizations -- remove some unneeded operations and make LLDrawPoolMaterials less branchy. --- indra/newview/lldrawpoolmaterials.cpp | 220 ++++++++++++++++++++-------------- 1 file changed, 131 insertions(+), 89 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 1c9fb55d06..8b591069fc 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -164,112 +164,154 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) LLCullResult::drawinfo_iterator begin = gPipeline.beginRenderMap(type); LLCullResult::drawinfo_iterator end = gPipeline.endRenderMap(type); + F32 lastIntensity = 0.f; + F32 lastFullbright = 0.f; + F32 lastMinimumAlpha = 0.f; + LLVector4 lastSpecular = LLVector4(0, 0, 0, 0); + + GLint intensity = mShader->getUniformLocation(LLShaderMgr::ENVIRONMENT_INTENSITY); + GLint brightness = mShader->getUniformLocation(LLShaderMgr::EMISSIVE_BRIGHTNESS); + GLint minAlpha = mShader->getUniformLocation(LLShaderMgr::MINIMUM_ALPHA); + GLint specular = mShader->getUniformLocation(LLShaderMgr::SPECULAR_COLOR); + + GLint specChannel = mShader->getUniformLocation(LLShaderMgr::SPECULAR_MAP); + GLint normChannel = mShader->getUniformLocation(LLShaderMgr::BUMP_MAP); + + LLTexture* lastNormalMap = nullptr; + LLTexture* lastSpecMap = nullptr; + LLTexture* lastDiffuse = nullptr; + + gGL.getTexUnit(diffuse_channel)->unbindFast(LLTexUnit::TT_TEXTURE); + + if (intensity > -1) + { + glUniform1f(intensity, lastIntensity); + } + + if (brightness > -1) + { + glUniform1f(brightness, lastFullbright); + } + + if (minAlpha > -1) + { + glUniform1f(minAlpha, lastMinimumAlpha); + } + + if (specular > -1) + { + glUniform4fv(specular, 1, lastSpecular.mV); + } + + LLVOAvatar* lastAvatar = nullptr; + for (LLCullResult::drawinfo_iterator i = begin; i != end; ++i) { + LL_PROFILE_ZONE_NAMED_CATEGORY_MATERIAL("materials draw loop"); LLDrawInfo& params = **i; - mShader->uniform4f(LLShaderMgr::SPECULAR_COLOR, params.mSpecColor.mV[0], params.mSpecColor.mV[1], params.mSpecColor.mV[2], params.mSpecColor.mV[3]); - mShader->uniform1f(LLShaderMgr::ENVIRONMENT_INTENSITY, params.mEnvIntensity); - - if (params.mNormalMap) - { - params.mNormalMap->addTextureStats(params.mVSize); - bindNormalMap(params.mNormalMap); - } - - if (params.mSpecularMap) - { - params.mSpecularMap->addTextureStats(params.mVSize); - bindSpecularMap(params.mSpecularMap); - } - - mShader->setMinimumAlpha(params.mAlphaMaskCutoff); - mShader->uniform1f(LLShaderMgr::EMISSIVE_BRIGHTNESS, params.mFullbright ? 1.f : 0.f); + if (specular > -1 && params.mSpecColor != lastSpecular) + { + lastSpecular = params.mSpecColor; + glUniform4fv(specular, 1, lastSpecular.mV); + } + if (intensity != -1 && lastIntensity != params.mEnvIntensity) { - LL_PROFILE_ZONE_SCOPED_CATEGORY_MATERIAL; - pushMaterialsBatch(params, mask, rigged); + lastIntensity = params.mEnvIntensity; + glUniform1f(intensity, lastIntensity); + } + + if (minAlpha > -1 && lastMinimumAlpha != params.mAlphaMaskCutoff) + { + lastMinimumAlpha = params.mAlphaMaskCutoff; + glUniform1f(minAlpha, lastMinimumAlpha); } - } -} -void LLDrawPoolMaterials::bindSpecularMap(LLViewerTexture* tex) -{ - mShader->bindTexture(LLShaderMgr::SPECULAR_MAP, tex); -} + F32 fullbright = params.mFullbright ? 1.f : 0.f; + if (brightness > -1 && lastFullbright != fullbright) + { + lastFullbright = fullbright; + glUniform1f(brightness, lastFullbright); + } -void LLDrawPoolMaterials::bindNormalMap(LLViewerTexture* tex) -{ - mShader->bindTexture(LLShaderMgr::BUMP_MAP, tex); -} + if (normChannel > -1 && params.mNormalMap != lastNormalMap) + { + lastNormalMap = params.mNormalMap; + llassert(lastNormalMap); + gGL.getTexUnit(normChannel)->bindFast(lastNormalMap); + } -void LLDrawPoolMaterials::pushMaterialsBatch(LLDrawInfo& params, U32 mask, bool rigged) -{ - LL_PROFILE_ZONE_SCOPED_CATEGORY_MATERIAL; - applyModelMatrix(params); - - bool tex_setup = false; - - //not batching textures or batch has only 1 texture -- might need a texture matrix - if (params.mTextureMatrix) - { - //if (mShiny) - { - gGL.getTexUnit(0)->activate(); - gGL.matrixMode(LLRender::MM_TEXTURE); - } - - gGL.loadMatrix((GLfloat*) params.mTextureMatrix->mMatrix); - gPipeline.mTextureMatrixOps++; - - tex_setup = true; - } - - if (mShaderLevel > 1) - { - if (params.mTexture.notNull()) - { - gGL.getTexUnit(diffuse_channel)->bindFast(params.mTexture); - } - else - { - gGL.getTexUnit(diffuse_channel)->unbindFast(LLTexUnit::TT_TEXTURE); - } - } - - if (params.mGroup) - { - params.mGroup->rebuildMesh(); - } + if (specChannel > -1 && params.mSpecularMap != lastSpecMap) + { + lastSpecMap = params.mSpecularMap; + llassert(lastSpecMap); + gGL.getTexUnit(specChannel)->bindFast(lastSpecMap); + } - // upload matrix palette to shader - if (rigged && params.mAvatar.notNull()) - { - const LLVOAvatar::MatrixPaletteCache& mpc = params.mAvatar->updateSkinInfoMatrixPalette(params.mSkinInfo); - U32 count = mpc.mMatrixPalette.size(); + if (params.mTexture != lastDiffuse) + { + lastDiffuse = params.mTexture; + if (lastDiffuse) + { + gGL.getTexUnit(diffuse_channel)->bindFast(lastDiffuse); + } + else + { + gGL.getTexUnit(diffuse_channel)->unbindFast(LLTexUnit::TT_TEXTURE); + } + } - if (count == 0) + // upload matrix palette to shader + if (rigged && params.mAvatar.notNull()) { - //skin info not loaded yet, don't render - return; + if (params.mAvatar != lastAvatar) + { + const LLVOAvatar::MatrixPaletteCache& mpc = params.mAvatar->updateSkinInfoMatrixPalette(params.mSkinInfo); + U32 count = mpc.mMatrixPalette.size(); + + if (count == 0) + { + //skin info not loaded yet, don't render + return; + } + + mShader->uniformMatrix3x4fv(LLViewerShaderMgr::AVATAR_MATRIX, + count, + FALSE, + (GLfloat*)&(mpc.mGLMp[0])); + } } - mShader->uniformMatrix3x4fv(LLViewerShaderMgr::AVATAR_MATRIX, - count, - FALSE, - (GLfloat*)&(mpc.mGLMp[0])); - } + applyModelMatrix(params); + + bool tex_setup = false; - //LLGLEnableFunc stencil_test(GL_STENCIL_TEST, params.mSelected, &LLGLCommonFunc::selected_stencil_test); + //not batching textures or batch has only 1 texture -- might need a texture matrix + if (params.mTextureMatrix) + { + gGL.getTexUnit(0)->activate(); + gGL.matrixMode(LLRender::MM_TEXTURE); - params.mVertexBuffer->setBufferFast(mask); - params.mVertexBuffer->drawRangeFast(LLRender::TRIANGLES, params.mStart, params.mEnd, params.mCount, params.mOffset); + gGL.loadMatrix((GLfloat*)params.mTextureMatrix->mMatrix); + gPipeline.mTextureMatrixOps++; - if (tex_setup) - { - gGL.getTexUnit(0)->activate(); - gGL.loadIdentity(); - gGL.matrixMode(LLRender::MM_MODELVIEW); + tex_setup = true; + } + + /*if (params.mGroup) // TOO LATE + { + params.mGroup->rebuildMesh(); + }*/ + + params.mVertexBuffer->setBufferFast(mask); + params.mVertexBuffer->drawRangeFast(LLRender::TRIANGLES, params.mStart, params.mEnd, params.mCount, params.mOffset); + + if (tex_setup) + { + gGL.getTexUnit(0)->activate(); + gGL.loadIdentity(); + gGL.matrixMode(LLRender::MM_MODELVIEW); + } } } - -- cgit v1.2.3 From ee1697a3911f521346f6ed8becedcfda048f220a Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Tue, 22 Nov 2022 14:22:27 -0600 Subject: SL-18678 Fix for Greg et al being too shiny (legacy materials in general being busted). --- indra/newview/lldrawpoolmaterials.cpp | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 8b591069fc..ec1ac6a88c 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -33,8 +33,6 @@ #include "llglcommonfunc.h" #include "llvoavatar.h" -S32 diffuse_channel = -1; - LLDrawPoolMaterials::LLDrawPoolMaterials() : LLRenderPass(LLDrawPool::POOL_MATERIALS) { @@ -98,7 +96,8 @@ void LLDrawPoolMaterials::beginDeferredPass(S32 pass) llassert(mShader->mRiggedVariant != nullptr); mShader = mShader->mRiggedVariant; } - mShader->bind(); + + gPipeline.bindDeferredShader(*mShader); if (LLPipeline::sRenderingHUDs) { @@ -108,8 +107,6 @@ void LLDrawPoolMaterials::beginDeferredPass(S32 pass) { mShader->uniform1i(LLShaderMgr::NO_ATMO, 0); } - - diffuse_channel = mShader->enableTexture(LLShaderMgr::DIFFUSE_MAP); } void LLDrawPoolMaterials::endDeferredPass(S32 pass) @@ -174,14 +171,15 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) GLint minAlpha = mShader->getUniformLocation(LLShaderMgr::MINIMUM_ALPHA); GLint specular = mShader->getUniformLocation(LLShaderMgr::SPECULAR_COLOR); - GLint specChannel = mShader->getUniformLocation(LLShaderMgr::SPECULAR_MAP); - GLint normChannel = mShader->getUniformLocation(LLShaderMgr::BUMP_MAP); + GLint diffuseChannel = mShader->enableTexture(LLShaderMgr::DIFFUSE_MAP); + GLint specChannel = mShader->enableTexture(LLShaderMgr::SPECULAR_MAP); + GLint normChannel = mShader->enableTexture(LLShaderMgr::BUMP_MAP); LLTexture* lastNormalMap = nullptr; LLTexture* lastSpecMap = nullptr; LLTexture* lastDiffuse = nullptr; - gGL.getTexUnit(diffuse_channel)->unbindFast(LLTexUnit::TT_TEXTURE); + gGL.getTexUnit(diffuseChannel)->unbindFast(LLTexUnit::TT_TEXTURE); if (intensity > -1) { @@ -254,11 +252,11 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) lastDiffuse = params.mTexture; if (lastDiffuse) { - gGL.getTexUnit(diffuse_channel)->bindFast(lastDiffuse); + gGL.getTexUnit(diffuseChannel)->bindFast(lastDiffuse); } else { - gGL.getTexUnit(diffuse_channel)->unbindFast(LLTexUnit::TT_TEXTURE); + gGL.getTexUnit(diffuseChannel)->unbindFast(LLTexUnit::TT_TEXTURE); } } -- cgit v1.2.3 From a710bf9067bd4c4217b9febc0ad277a1636ec882 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Mon, 9 Jan 2023 15:18:57 -0600 Subject: SL-18869 Optimizations -- Use _mm_prefetch to cut down on cache misses when iterating over render batches. --- indra/newview/lldrawpoolmaterials.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index ec1ac6a88c..858fb871d3 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -203,11 +203,13 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) LLVOAvatar* lastAvatar = nullptr; - for (LLCullResult::drawinfo_iterator i = begin; i != end; ++i) + for (LLCullResult::drawinfo_iterator i = begin; i != end; ) { LL_PROFILE_ZONE_NAMED_CATEGORY_MATERIAL("materials draw loop"); LLDrawInfo& params = **i; + LLCullResult::increment_iterator(i, end); + if (specular > -1 && params.mSpecColor != lastSpecular) { lastSpecular = params.mSpecColor; -- cgit v1.2.3 From 7bd9d21e19b923096ba2b5ea3cbc8be3e13d7aa0 Mon Sep 17 00:00:00 2001 From: RunitaiLinden Date: Thu, 19 Jan 2023 09:13:45 -0600 Subject: Optimizations, decruft, and intel compatibility pass (#53) SL-18869, SL-18772 Overhaul VBO management, restore occlusion culling, intel compatibility pass, etc --- indra/newview/lldrawpoolmaterials.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 858fb871d3..735f32ddbb 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -156,8 +156,6 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) type += 1; } - U32 mask = mShader->mAttributeMask; - LLCullResult::drawinfo_iterator begin = gPipeline.beginRenderMap(type); LLCullResult::drawinfo_iterator end = gPipeline.endRenderMap(type); @@ -304,8 +302,8 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) params.mGroup->rebuildMesh(); }*/ - params.mVertexBuffer->setBufferFast(mask); - params.mVertexBuffer->drawRangeFast(LLRender::TRIANGLES, params.mStart, params.mEnd, params.mCount, params.mOffset); + params.mVertexBuffer->setBuffer(); + params.mVertexBuffer->drawRange(LLRender::TRIANGLES, params.mStart, params.mEnd, params.mCount, params.mOffset); if (tex_setup) { -- cgit v1.2.3 From 830cb6b66551025285120fb628f0b5ebf3841756 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Fri, 3 Feb 2023 17:18:39 -0600 Subject: SL-19148 Decruft some forward shaders and drawpools. Fix HUDs being in wrong color space. --- indra/newview/lldrawpoolmaterials.cpp | 9 --------- 1 file changed, 9 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 735f32ddbb..6a7e05ac74 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -98,15 +98,6 @@ void LLDrawPoolMaterials::beginDeferredPass(S32 pass) } gPipeline.bindDeferredShader(*mShader); - - if (LLPipeline::sRenderingHUDs) - { - mShader->uniform1i(LLShaderMgr::NO_ATMO, 1); - } - else - { - mShader->uniform1i(LLShaderMgr::NO_ATMO, 0); - } } void LLDrawPoolMaterials::endDeferredPass(S32 pass) -- cgit v1.2.3 From dc813181a51ad2c22264e93a3c235cbf796b24ed Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Thu, 27 Apr 2023 12:25:50 -0700 Subject: More post-merge fixes after DRTVWR-559 & DRTVWR-539 merge --- indra/newview/lldrawpoolmaterials.cpp | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 3144f9a2fa..e025651cce 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -156,17 +156,6 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) F32 lastFullbright = 0.f; F32 lastMinimumAlpha = 0.f; LLVector4 lastSpecular = LLVector4(0, 0, 0, 0); - #if 0 // TODO merge brad move this down into LLCullResult begin/end loop - if(params.mFace) - { - LLViewerObject* vobj = (LLViewerObject *)params.mFace->getViewerObject(); - - if( vobj && vobj->isAttachment() ) - { - trackAttachments( vobj, params.mFace->isState(LLFace::RIGGED), &ratPtr ); - } - } - #endif GLint intensity = mShader->getUniformLocation(LLShaderMgr::ENVIRONMENT_INTENSITY); GLint brightness = mShader->getUniformLocation(LLShaderMgr::EMISSIVE_BRIGHTNESS); @@ -212,6 +201,18 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) LLCullResult::increment_iterator(i, end); +#if 0 // TODO SL-19656 figure out how to reenable trackAttachments() + if(params.mFace) + { + LLViewerObject* vobj = (LLViewerObject *)params.mFace->getViewerObject(); + + if( vobj && vobj->isAttachment() ) + { + trackAttachments( vobj, params.mFace->isState(LLFace::RIGGED), &ratPtr ); + } + } +#endif + if (specular > -1 && params.mSpecColor != lastSpecular) { lastSpecular = params.mSpecColor; -- cgit v1.2.3 From 334d71e9107ae3c4d35b181f2ed6e5c9ff1de519 Mon Sep 17 00:00:00 2001 From: RunitaiLinden Date: Mon, 1 May 2023 17:05:09 -0500 Subject: SL-19656 Rewrite avatar and attachment render metrics to not interfere with render pipe and be representative of actual render cost instead of driver synchronization time. * SL-19656 Rewrite avatar and attachment render metrics to not interfere with render pipe and be representative of actual render cost instead of driver synchronization time. * SL-19656 Remove now dead code (trackAttachments et al). * SL-19656 Fix for crash on GL <= 3.2 --- indra/newview/lldrawpoolmaterials.cpp | 14 -------------- 1 file changed, 14 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index e025651cce..6a7e05ac74 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -32,7 +32,6 @@ #include "pipeline.h" #include "llglcommonfunc.h" #include "llvoavatar.h" -#include "llperfstats.h" LLDrawPoolMaterials::LLDrawPoolMaterials() : LLRenderPass(LLDrawPool::POOL_MATERIALS) @@ -151,7 +150,6 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) LLCullResult::drawinfo_iterator begin = gPipeline.beginRenderMap(type); LLCullResult::drawinfo_iterator end = gPipeline.endRenderMap(type); - std::unique_ptr ratPtr{}; F32 lastIntensity = 0.f; F32 lastFullbright = 0.f; F32 lastMinimumAlpha = 0.f; @@ -201,18 +199,6 @@ void LLDrawPoolMaterials::renderDeferred(S32 pass) LLCullResult::increment_iterator(i, end); -#if 0 // TODO SL-19656 figure out how to reenable trackAttachments() - if(params.mFace) - { - LLViewerObject* vobj = (LLViewerObject *)params.mFace->getViewerObject(); - - if( vobj && vobj->isAttachment() ) - { - trackAttachments( vobj, params.mFace->isState(LLFace::RIGGED), &ratPtr ); - } - } -#endif - if (specular > -1 && params.mSpecColor != lastSpecular) { lastSpecular = params.mSpecColor; -- cgit v1.2.3 From bdb53fd56d56c659941e7e63f83cefc366acef6d Mon Sep 17 00:00:00 2001 From: RunitaiLinden Date: Thu, 16 Nov 2023 16:46:12 -0600 Subject: SL-20611 Make haze effect local lights -- move sky and water haze to their own passes and unify sky and water haze in forward rendering shaders. --- indra/newview/lldrawpoolmaterials.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'indra/newview/lldrawpoolmaterials.cpp') diff --git a/indra/newview/lldrawpoolmaterials.cpp b/indra/newview/lldrawpoolmaterials.cpp index 6a7e05ac74..c0e4ed38c1 100644 --- a/indra/newview/lldrawpoolmaterials.cpp +++ b/indra/newview/lldrawpoolmaterials.cpp @@ -82,14 +82,7 @@ void LLDrawPoolMaterials::beginDeferredPass(S32 pass) U32 idx = shader_idx[pass]; - if (LLPipeline::sUnderWaterRender) - { - mShader = &(gDeferredMaterialWaterProgram[idx]); - } - else - { - mShader = &(gDeferredMaterialProgram[idx]); - } + mShader = &(gDeferredMaterialProgram[idx]); if (rigged) { -- cgit v1.2.3