Skip to content
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

Fix non decimal format floats in TangentUtils.glsllib #2389

Merged
merged 1 commit into from
Mar 6, 2025

Conversation

yaRnMcDonuts
Copy link
Member

I also added a line of code that I had previously removed from the tangent calculations that may fix some minor inaccuracies in shading and lighting direction (although it was very minor and barely noticeable).

I previously removed that line of code because it was also flipping the y component of normal map (which is better done by the NORMAL_TYPE param) but then I realized this line of code also flips the x component of the normal map which is likely important for the tangent calculation that follows. So I just updated it to only multiply the x component by -1 and will leave the y component flipping up to NORMAL_TYPE so users can change it as needed.

I also added a line of code that I had previously removed from the tangent calculations that may fix some minor inaccuracies in shading and lighting direction (although it was very minor and barely noticeable).

I previously removed that line of code because it was also flipping the y component of normal map (which is better done by the NORMAL_TYPE param) but then I realized this line of code also flips the x component of the normal map which is likely important for the tangent calculation that follows. So I just updated it to only multiply the x component by -1 and will leave the y component flipping up to NORMAL_TYPE so users can change it as needed.
@yaRnMcDonuts yaRnMcDonuts merged commit d233f1d into master Mar 6, 2025
15 checks passed
@yaRnMcDonuts yaRnMcDonuts deleted the yaRnMcDonuts-patch-3 branch March 6, 2025 22:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant