-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Native unclipped depth on supported platforms #16095
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome!
Technically I think I should have a version of the meshlet software raster that does depth clipping for all other views besides directional light shadows, but I'm not 100% sure if this even matters in practice so I've elected to just ignore it for now. |
Ready for review. Please post perf tests, I was unable to find a good comparison. Also please double check that the fragment shader is actually omitted when the emulation is off, renderdoc was confusing when I tried to check. |
@superdump when we set the frag depth to the unclipped depth, should we be writing 1 / unclipped depth or something? Is what we have correct? |
:/ yeah that's what I saw... Confusing. |
Ok, so it doesn't improve FPS because we're still CPU bound, but on scenes with a lot of shadow fragments, we are faster now. I think we're good to merge :) |
Objective
Solution
Testing
Migration Guide
MeshPipelineKey::DEPTH_CLAMP_ORTHO
is nowMeshPipelineKey::UNCLIPPED_DEPTH_ORTHO
DEPTH_CLAMP_ORTHO
shaderdef has been renamed toUNCLIPPED_DEPTH_ORTHO_EMULATION
clip_position_unclamped: vec4<f32>
is nowunclipped_depth: f32