-
-
Notifications
You must be signed in to change notification settings - Fork 21.5k
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
DirectionalLight3D is not working correctly when light is pointing away #68143
Comments
This looks like it could be a shadow pancaking issue, but I can't confirm as I can't reproduce locally. |
Most likely, your meshes are corrupted and this is a duplicate of either upgrading from godot 3 #63550 or upgrading from an earlier version of godot 4 #64854. You can fix it by reimporting all of your meshes in the latest version, or deleting |
@clayjohn @tinmanjuggernaut , I've uploaded a new project which should be able to replicate: https://github.com/Mikeysax/example-project-for-godot-bug-68143 I can try your suggestion @tinmanjuggernaut , but the meshes being used are MeshInstances generated by Godot. UPDATE: The imported suggestion did not change the issue |
I see, if they are native meshes, then what I wrote does not apply. Yeah Godot leaks light all over the place. It's not a ray tracer, (though the light baker is). Casting a shadow from a 100x100m object onto 4x1m objects right next to it with a 100 shadow distance is a challenge. Try adjusting the scale of your shadow casters and bring them into the same order of magnitude. Increasing shadow distance to 1000 is costly, though 100 is too short. 256-400 is good for modern and previous generation cards. You can create mesh boxes and under Geometry mark them as cast shadow cast only. Then you can use them as flags to block light the way a gaffer would shape light on a film set. https://www.youtube.com/watch?v=ShFk1Ao9sBw |
I see; thank you for the tips and help! I was aware of .gitignore although I was not used to what should be excluded from a godot project for source control. |
Godot version
4.0beta3
System information
PopOS 22.04, 5.19.0-76051900-generic kernel, Ryzen 6800h, Radeon 6700m, amdgpu, Vulkan
Issue description
Utilizing DirectionalLight3D and Environment, I'm seeing weird light behavior when the scene should be completely dark. I have a day night cycle and it's producing unexpected results and I'm not sure why:
Here is a video to demonstrate:
Peek.2022-11-01.20-21.mp4
Steps to reproduce
This is an old project, but it can be reproduced here:
https://github.com/Mikeysax/example-project-for-godot-bug-68143
Here are screenshots of the environment if that helps:
Minimal reproduction project
https://github.com/Mikeysax/example-project-for-godot-bug-68143
The text was updated successfully, but these errors were encountered: