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

Sky Rework #827

Open
dashodanger opened this issue Jan 11, 2025 · 1 comment
Open

Sky Rework #827

dashodanger opened this issue Jan 11, 2025 · 1 comment
Labels
enhancement New feature or request implementation Change or improvement to how an existing feature is implemented

Comments

@dashodanger
Copy link
Member

The current method (assuming Simple Skies are Off) of writing "sky planes" and "sky walls" to the depth buffer and then drawing the sky while juggling depth testing is a bit convoluted and doesn't mesh well with the Sokol rendering path.

Ideally the sky would simply be drawn once before any other rendering or BSP traversal occurs and without needing to determine whether or not the sky "should" be drawn in a frame. The downside of this is that we would still need a way to determine sky planes and walls for the purposes of not drawing anything "behind" them.

@dashodanger dashodanger added enhancement New feature or request implementation Change or improvement to how an existing feature is implemented labels Jan 11, 2025
@dashodanger dashodanger added this to the EDGE-Classic 1.5 Release milestone Jan 11, 2025
@pbdot
Copy link
Collaborator

pbdot commented Jan 11, 2025

I believe GZDoom is using the stencil buffer for portals, that are generated while traversing and hit sky walls/planes. This would probably simplify this quite a bit. We would have to add support for stencil commands into the customized sokol gl, which think would be pretty easy.

https://github.com/ZDoom/gzdoom/blob/master/src/rendering/hwrenderer/scene/hw_portal.cpp

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request implementation Change or improvement to how an existing feature is implemented
Projects
None yet
Development

No branches or pull requests

2 participants