-
Notifications
You must be signed in to change notification settings - Fork 855
Update algorithm for specular occlusion #5312
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
Conversation
Hi! This comment will help you figure out which jobs to run before merging your PR. The suggestions are dynamic based on what files you have changed. HDRP SRP Core Depending on the scope of your PR, you may need to run more jobs than what has been suggested. Please speak to your lead or a Graphics SDET (#devs-graphics-automation) if you are unsure. |
Note for reviever: Before merging we want to know what method make sense and then we will remove the other one. Also be sure it works with all our shader type. |
adding QA for awareness but already tested by artists 🙂 |
com.unity.render-pipelines.high-definition/Runtime/Material/LayeredLit/LayeredLit.shader
Show resolved
Hide resolved
com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitProperties.hlsl
Show resolved
Hide resolved
com.unity.render-pipelines.high-definition/Runtime/Material/Lit/LitProperties.hlsl
Show resolved
Hide resolved
PR tested by the artsits. No need for futher QA. Merging |
Purpose of this PR
This PR is updating the algorithm for specular occlusion when using bent normals + AO.
This new version reduces specular occlusion sharpness for high smoothness materials, and reduces over darkenning of surfaces when looking at grazing angles.
Also changed default value for specular occlusion for new shader graphs. Previous was "Off", now it's "From AO" to match default value of the Lit shader
Comparison of the different options:

Before this PR is "From Bent Normals", new algorithm is "From Spherical Gaussians"
Both models have high smoothness in the gif below, all lighting is from HDRI Sky
Added a section in
Shader Code
of upgrade guide about function renaming.Added screenshot in
Whats new
guideTesting status
https://confluence.unity3d.com/pages/viewpage.action?spaceKey=HDRP&title=Specular+Occlusion