diff options
Diffstat (limited to 'indra/newview')
-rwxr-xr-x | indra/newview/pipeline.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 05390f64f0..9aa375767b 100755 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -8695,6 +8695,12 @@ void LLPipeline::renderDeferredLighting() unbindDeferredShader(gDeferredSpotLightProgram); } + //reset mDeferredVB to fullscreen triangle + mDeferredVB->getVertexStrider(vert); + vert[0].set(-1,1,0); + vert[1].set(-1,-3,0); + vert[2].set(3,1,0); + { LLGLDepthTest depth(GL_FALSE); @@ -8713,10 +8719,6 @@ void LLPipeline::renderDeferredLighting() F32 far_z = 0.f; - bindDeferredShader(gDeferredMultiLightProgram[0]); - - mDeferredVB->setBuffer(LLVertexBuffer::MAP_VERTEX); - while (!fullscreen_lights.empty()) { LLFastTimer ftm(FTM_FULLSCREEN_LIGHTS); @@ -8742,13 +8744,11 @@ void LLPipeline::renderDeferredLighting() gDeferredMultiLightProgram[idx].uniform1f(LLShaderMgr::MULTI_LIGHT_FAR_Z, far_z); far_z = 0.f; count = 0; - mDeferredVB->setBuffer(LLVertexBuffer::MAP_VERTEX); + mDeferredVB->setBuffer(LLVertexBuffer::MAP_VERTEX); mDeferredVB->drawArrays(LLRender::TRIANGLES, 0, 3); unbindDeferredShader(gDeferredMultiLightProgram[idx]); } } - - unbindDeferredShader(gDeferredMultiLightProgram[0]); bindDeferredShader(gDeferredMultiSpotLightProgram); |