Reduce seam in water refraction#1718
Closed
URAKOLOUY5 wants to merge 3 commits intoValveSoftware:masterfrom
Closed
Reduce seam in water refraction#1718URAKOLOUY5 wants to merge 3 commits intoValveSoftware:masterfrom
URAKOLOUY5 wants to merge 3 commits intoValveSoftware:masterfrom
Conversation
ficool2
reviewed
Dec 20, 2025
| m_DrawFlags = DF_RENDER_REFRACTION | DF_CLIP_Z | | ||
| DF_RENDER_UNDERWATER | DF_FUDGE_UP | | ||
| DF_DRAW_ENTITITES ; | ||
| DF_DRAW_ENTITITES | DF_RENDER_ABOVEWATER; |
Contributor
There was a problem hiding this comment.
This leads to a significant performance penalty as geometry above the water will be rendered twice (CAboveWaterView setup also adds this flag)
Removing this flag shows that the offset height hack doesn't work in isolation. The flag by itself fixes the issue, but this trade off in performance is not worth it
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



This PR adjusts water clipping plane by 4 units up, enough to fix visible seam
Note: it leads to x2 performance usage as it renders view above but clips it early
Before:

After:
