-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Fixes sheen intensity #4697
Fixes sheen intensity #4697
Conversation
…ngine into gsterbrant_sheen_spec_fixes
…heen was a mistake. Also revert the mip offset reflection sampling. Also, sheen should not be a factor of the materials reflectivity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent. Do you advocate including this fix in a 1.57.1? Or wait until the next minor bump?
I hope this can go in 1.57.1 as it's a nasty bug affecting all cloth materials. |
This PR is also updating clearcoat. Is that intended? You don't mention this in the description. |
@slimbuck Thanks! Had forgotten about that. Added it to the comment. |
* Fix double clearcoat spec multiplication. * Use CC fresnel for lights * Use CC fresnel for lights * Add reflection sample with base mip offset for materials * Defer multiplication of sheen specular color to combine step. * We don't use reciprocal PI for energy preservation, so doing it for sheen was a mistake. Also revert the mip offset reflection sampling. Also, sheen should not be a factor of the materials reflectivity.
Description
Our analytical approach inspired by Three.js inconsistently divides by PI to balance the energy over the hemisphere. This caused a strong reduction in sheen light intensities.
Furthermore, we also used the roughness of the sheen to sample different environment mips, but sampling the lowest mip is more correct as reflections will always be extremely rough, seeing as sheen is simulating quite big microfibers.
Before:
After:
This PR also fixes an issue where clear coat was using the specular color to tint reflections. According to the glTF spec, the f0 for clear coat is always white.