From efd838143dd5aa36bbb1b1a06fbfaaa8052bbbfd Mon Sep 17 00:00:00 2001 From: John-Michael Mulesa Date: Mon, 21 Sep 2026 23:01:00 -0400 Subject: [PATCH] Stop compositing a special effect on frames that did not request it R_AddSpecialEffects issues no RB_DrawSpecialEffects command once every effect is off, so the mask and depth captures that command leaves in rbRVSpecialActiveMask and rbRVSpecialBlurPrepared are never refreshed. RB_DisplaySpecialEffects kept honouring them, and went on compositing the last frame's blur on every later frame. Answering the multiplayer join card is the common way in: the game clears its soft focus and the renderer's blur bit, yet the world stays blurred, from a depth mask captured when the card was up, until a vid_restart. Only honour that state on the frame whose command produced it, as the special-frame record at the end of the view already does. Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_017RU1i6R3gN4cdKRELGiCEc --- src/renderer/draw_common.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/renderer/draw_common.cpp b/src/renderer/draw_common.cpp index d4fbfe753..b60d3b3b7 100644 --- a/src/renderer/draw_common.cpp +++ b/src/renderer/draw_common.cpp @@ -8028,6 +8028,12 @@ static void RB_DisplaySpecialEffects( const viewEntity_t *viewEnts, bool prePass if ( backEnd.viewDef == NULL || !glConfig.GLSLProgramAvailable ) { return; } + // R_AddSpecialEffects issues no command once every effect is off, so the + // mask and captures RB_DrawSpecialEffects left behind belong to an earlier + // frame; honouring them keeps compositing that frame's blur indefinitely. + if ( rbRVSpecialCommandFrame != backEnd.frameCount ) { + return; + } if ( prePass ) { // Legacy blur is authored as a fullscreen 2D overlay. The 3D pass only captures