Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Investigate using stenciled rendering planes to replace the out-of-view fragment discard technique. #836

Open
bryanedds opened this issue Jul 20, 2024 · 0 comments
Labels
enhancement investigation a topic involving investigation

Comments

@bryanedds
Copy link
Owner

bryanedds commented Jul 20, 2024

We used to elide fragments of surfaces that are beyond the viewable range in the shader with GLSL discard, but that was waaaaay to inefficient (all uses of discard in shaders have since been removed). However, we might be able to efficiently restore this functionality with render stenciling, so we should investigate this.

Relevant TODO in code here -

// TODO: see if we can use this to set up rendering stencil planes (presence would also have to become a key in batching if it isn't already).
member this.DepthCutoff =
match this with
| Omnipresent -> Constants.Render.FarPlaneDistanceOmnipresent
| Imposter -> -Constants.Render.NearPlaneDistanceImposter
| Exterior | Interior -> Constants.Render.FarPlaneDistanceExterior

@bryanedds bryanedds added enhancement investigation a topic involving investigation labels Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement investigation a topic involving investigation
Projects
None yet
Development

No branches or pull requests

1 participant