diff options
Diffstat (limited to 'indra/newview/lldrawpoolpbropaque.cpp')
-rw-r--r-- | indra/newview/lldrawpoolpbropaque.cpp | 48 |
1 files changed, 12 insertions, 36 deletions
diff --git a/indra/newview/lldrawpoolpbropaque.cpp b/indra/newview/lldrawpoolpbropaque.cpp index 2f710e570b..d0c588b65a 100644 --- a/indra/newview/lldrawpoolpbropaque.cpp +++ b/indra/newview/lldrawpoolpbropaque.cpp @@ -1,6 +1,6 @@ /** * @file lldrawpoolpbropaque.cpp - * @brief LLDrawPoolPBROpaque class implementation + * @brief LLDrawPoolGLTFPBR class implementation * * $LicenseInfo:firstyear=2022&license=viewerlgpl$ * Second Life Viewer Source Code @@ -31,54 +31,24 @@ #include "llviewershadermgr.h" #include "pipeline.h" -LLDrawPoolPBROpaque::LLDrawPoolPBROpaque() : - LLRenderPass(POOL_PBR_OPAQUE) +LLDrawPoolGLTFPBR::LLDrawPoolGLTFPBR() : + LLRenderPass(POOL_GLTF_PBR) { } -void LLDrawPoolPBROpaque::prerender() +void LLDrawPoolGLTFPBR::renderDeferred(S32 pass) { - mShaderLevel = LLViewerShaderMgr::instance()->getShaderLevel(LLViewerShaderMgr::SHADER_OBJECT); -} - -// Forward -void LLDrawPoolPBROpaque::beginRenderPass(S32 pass) -{ -} - -void LLDrawPoolPBROpaque::endRenderPass( S32 pass ) -{ -} - -void LLDrawPoolPBROpaque::render(S32 pass) -{ -} - -void LLDrawPoolPBROpaque::renderDeferred(S32 pass) -{ - if (!gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_MATERIALS)) - { - return; - } - - const U32 type = LLPipeline::RENDER_TYPE_PASS_PBR_OPAQUE; - if (!gPipeline.hasRenderType(type)) - { - return; - } + const U32 type = LLPipeline::RENDER_TYPE_PASS_GLTF_PBR; gGL.flush(); - LLGLDisable blend(GL_BLEND); - LLGLDisable alpha_test(GL_ALPHA_TEST); - LLVOAvatar* lastAvatar = nullptr; U64 lastMeshId = 0; for (int i = 0; i < 2; ++i) { bool rigged = (i == 1); - LLGLSLShader* shader = &gDeferredPBROpaqueProgram; + LLGLSLShader* shader = LLPipeline::sShadowRender ? &gDeferredShadowAlphaMaskProgram : &gDeferredPBROpaqueProgram; U32 vertex_data_mask = getVertexDataMask(); if (rigged) @@ -138,3 +108,9 @@ void LLDrawPoolPBROpaque::renderDeferred(S32 pass) LLGLSLShader::sCurBoundShaderPtr->unbind(); } + +void LLDrawPoolGLTFPBR::renderShadow(S32 pass) +{ + renderDeferred(pass); +} + |