Fix shadow rendering in Compatibility#63
Open
Kaleb-Reid wants to merge 1 commit into
Open
Conversation
Member
|
I think multiview is used in VR so this might break vr if we only use the first camera. Not sure. |
Author
|
@fire I don't think that this should break VR unless it was already broken on this branch. I just moved where we override the projection matrix so that it doesn't affect shadows / particles. |
Member
|
I think there is a vulkan software development kit location change that breaks the build. |
Member
|
Working on an update on https://github.com/V-Sekai/godot/tree/vsk-override-projection-4.6 on godot master. |
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.
I bisected broken directional shadows in the Compatibility renderer in my builds to the commit I cherry-picked from this branch. The shadows would simply not appear.
render_data.cam_projectionis set at three points in Compatibility, once for the main camera projection on line 2261, once for rendering particle heightfields on line 3682, and once for shadow passes on line 2151. I'm guessing for shadow / particle rendering we do not want to use the main camera projection.This seemed to fix the shadows in the short time I tested it, not sure if this breaks anything else.