Skip to content

Commit c67861f

Browse files
authored
Merge pull request #311 from gwigz/gwigz/fix-render-resolution-divisor
Fix FXAA pass ignoring RenderResolutionDivisor
2 parents 03a5af0 + 11db3e8 commit c67861f

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

indra/newview/pipeline.cpp

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8372,12 +8372,9 @@ void LLPipeline::applyFXAA(LLRenderTarget* src, LLRenderTarget* dst)
83728372
mFXAAMap.bindTexture(0, channel, LLTexUnit::TFO_BILINEAR);
83738373
}
83748374

8375-
gGLViewport[0] = gViewerWindow->getWorldViewRectRaw().mLeft;
8376-
gGLViewport[1] = gViewerWindow->getWorldViewRectRaw().mBottom;
8377-
gGLViewport[2] = gViewerWindow->getWorldViewRectRaw().getWidth();
8378-
gGLViewport[3] = gViewerWindow->getWorldViewRectRaw().getHeight();
8379-
8380-
glViewport(gGLViewport[0], gGLViewport[1], gGLViewport[2], gGLViewport[3]);
8375+
// The destination is an FBO; bindTarget already set its viewport.
8376+
// Forcing the full world-view viewport here makes RenderResolutionDivisor
8377+
// write only the lower-left fraction of the reduced-size target.
83818378

83828379
F32 scale_x = (F32)width / mFXAAMap.getWidth();
83838380
F32 scale_y = (F32)height / mFXAAMap.getHeight();

0 commit comments

Comments
 (0)