Rendering bug in Stacked-sector portals and reflective flats fix #3183
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Stacked-sector and planemirror portals stencil rewrite to address rendering bug with stencil cap.
Discord user named "Mud" reported a rendering bug under "technical-issues" titled "Visual bug with portals", wherein viewing a stacked-sector portal from the top results in a small (often triangular) shape near the center of the view. They uploaded this video-recording from one of their maps:
2025-07-03_19-46-30.mp4
A similar visual bug occurs in reflective flats.
The size of the visual artifact depends on the absolute height/z-value of the plane containing the sector-portal or reflection. The following maps have all flat heights close to -32000.f to exaggerate the effect. In most normal maps, the artifacts will cover a small area of the screen.
Just load the maps and look down. Move around. Duck. etc.
visual_bug_floormaps.zip
The effect can be made to appear in reflective ceilings or sector portals when viewed from above too. The absolute heights will need to be close to +32000.f to increase the size of the artifacts then.