-
-
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
many_foxes are all black #6528
Comments
No issues on my end AdapterInfo { name: "NVIDIA GeForce RTX 2070 SUPER", vendor: 4318, device: 7812, device_type: DiscreteGpu, driver: "NVIDIA", driver_info: "520.56.06", backend: Vulkan } |
I also have a AMD Radeon RX 6600, I’ll check that tomorrow :) |
Could you run with
|
|
Yes, the issue is caused by the directional light (as @DasLixou suspected). Here is how the scene looks for me with the light removed |
oh. so its a problem with directional light that only gets caused on some graphic drivers? |
That's not what broke it for me. I ran a git bisect on it and the breaking commit is 681c9c6. |
# Objective - Morten Mikkelsen clarified that the world normal and tangent must be normalized in the vertex stage and the interpolated values must not be normalized in the fragment stage. This is in order to match the mikktspace approach exactly. - Fixes #5514 by ensuring the tangent basis matrix (TBN) is orthonormal ## Solution - Normalize the world normal in the vertex stage and not the fragment stage - Normalize the world tangent xyz in the vertex stage - Take into account the sign of the determinant of the local to world matrix when calculating the bitangent --- ## Changelog - Fixed - scaling a model that uses normal mapping now has correct lighting again
I'll open a PR for it, but as the comment states, there is a reason the algorithm does not want this vector to be normalized. So I don't know what the proper way to fix this is. |
Could you test this: #6543? |
Looks good on my RX590. |
# Objective - Make the many foxes not unnecessarily bright. Broken since bevyengine#5666. - Fixes bevyengine#6528 ## Solution - In bevyengine#5666 normalisation of normals was moved from the fragment stage to the vertex stage. However, it was not added to the vertex stage for skinned normals. The many foxes are skinned and their skinned normals were not unit normals. which made them brighter. Normalising the skinned normals fixes this. --- ## Changelog - Fixed: Non-unit length skinned normals are now normalized.
Bevy version
1914a3f
Relevant system information
AdapterInfo { name: "AMD Radeon RX 6600", vendor: 4098, device: 29695, device_type: DiscreteGpu, driver: "AMD proprietary driver", driver_info: "22.9.2", backend: Vulkan }
What you did
cargo run --release --example many_foxes
What went wrong
foxes should be orange with a texture, but render black.
The text was updated successfully, but these errors were encountered: