From 1b162ececc811e2663a39b734d2782af7b97faac Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Thu, 13 Jan 2022 00:04:32 +0100 Subject: [PATCH] - do not add two-sided walls outside of the visible range to the clipper This caused a render glitch in Duke E4L2. --- source/core/rendering/scene/hw_bunchdrawer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/rendering/scene/hw_bunchdrawer.cpp b/source/core/rendering/scene/hw_bunchdrawer.cpp index 5c304885b..d07164c64 100644 --- a/source/core/rendering/scene/hw_bunchdrawer.cpp +++ b/source/core/rendering/scene/hw_bunchdrawer.cpp @@ -291,7 +291,7 @@ int BunchDrawer::ClipLine(int aline, bool portal) if (portal) clipper->RemoveClipRange(startAngle, endAngle); else { - if (topclip < FLT_MAX || bottomclip > -FLT_MAX) + if ((topclip < FLT_MAX || bottomclip > -FLT_MAX) && !dontclip) { clipper->AddWindowRange(startAngle, endAngle, topclip, bottomclip, viewz); //Printf("\nWall %d from %2.3f - %2.3f, (%2.3f, %2.3f) (passing)\n", line, bamang(startAngle).asdeg(), bamang(endAngle).asdeg(), topclip, bottomclip);