-
-
Notifications
You must be signed in to change notification settings - Fork 35.6k
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
Allow to Use Roughness for SSR in Three.js #28752
Comments
@gonnavis Do you mind looking at this issue? |
Sorry, I'm busy at work and might not have much time recently. I've tried something similar before #21487, but full PBR integration was too challenging for me and I couldn't complete it yet. However, it might still be helpful as a reference. |
@WestLangley I wonder what your opinion is on this topic. Right now, |
Description
I am using post-processing with WebGL 2.0 and encountered a limitation in the SSRShader. Currently, the shader uses only the metalness value to determine if SSR should be applied to a fragment:
This limitation results in the same glossy reflection for all objects, regardless of their surface properties.
Solution
I propose to extend the SSRShader functionality by utilizing both metalness (for opacity/alpha SSR) and roughness (to determine the strength of SSR reflections). I have customized the shader to use ORM textures and modified it as follows:
This modification allows achieving more realistic reflections by adjusting their strength based on the roughness value.
Alternatives
Currently, the only alternative is to manually customize the shader code to incorporate roughness, as shown above. This approach is not ideal for all users and may lead to inconsistencies and maintenance challenges.
Additional context
Supporting roughness in the SSRShader to blur reflections based on roughness strength would allow for more accurate and varied reflections, improving visual realism for both metallic and non-metallic surfaces. This enhancement would greatly benefit the Three.js community and enhance the overall rendering quality.
Thank you for considering this request.
The text was updated successfully, but these errors were encountered: