File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -1625,11 +1625,19 @@ void RB_FXAA()
16251625 GL_BindToTMU ( 0 , tr.currentRenderImage [backEnd.currentMainFBO ] )
16261626 );
16271627
1628+ // The framebuffer should use GL_LINEAR for FXAA to work.
1629+ glTexParameterf ( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR );
1630+ glTexParameterf ( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR );
1631+
16281632 // This shader is run last, so let it render to screen.
16291633 R_BindNullFBO ();
16301634
16311635 Tess_InstantScreenSpaceQuad ();
16321636
1637+ // Restore GL_NEAREST to not break other effects.
1638+ glTexParameterf ( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
1639+ glTexParameterf ( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
1640+
16331641 GL_CheckErrors ();
16341642}
16351643
You can’t perform that action at this time.
0 commit comments