[graphics] Fix issue with envmap math #3862
Merged
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.
A few people in the discord noticed that the shiny part of the subrails looks different between PS2 and OpenGOAL. I looked into this and found a bug where the length of the normals was half what they should have been. Earlier this didn't matter because I normalized them in the shader, but at some point I removed that when refactoring other parts.
I'm not completely convinced we have the intensity/tint multiplier working correctly, but this is at least a step in the right direction.
nrm_before-2025-02-16_16.03.00.mp4
nrm_after-2025-02-16_16.01.36.mp4
For fun, here's this fix, plus a random doubling of the envmap effect strength:
double-2025-02-16_16.13.22.mp4