-
-
Notifications
You must be signed in to change notification settings - Fork 36.1k
Closed
Labels
Milestone
Description
Description
To repro, modify examples/webgl_shadowmap.html by passing reverseDepthBuffer: true into the WebGLRenderer constructor.
To get anything to render at all, you will also need to add renderer.getContext().clearDepth(0) (see my comment in #29579).
After these modifications, the demo looks okay except that there are no shadows.
Solution
Ideally shadow mapping is supported without requiring clients to write any extra code, since DepthBuffer in WebGLState already flips the depth function & depth clear value at a low level. I have not yet been able to find the missing piece.
Alternatives
Alternatively, maybe the onus is on the applications to handle this in the onBeforeShadow hook?
Additional context
No response