Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/intern/cycles/kernel/closure/bsdf_microfacet.h b/intern/cycles/kernel/closure/bsdf_microfacet.h
- --- a/intern/cycles/kernel/closure/bsdf_microfacet.h
- +++ b/intern/cycles/kernel/closure/bsdf_microfacet.h
- @@ -342,8 +342,9 @@ ccl_device float3 bsdf_microfacet_ggx_eval_reflect(const ShaderClosure *sc, cons
- float G = G1o * G1i;
- /* eq. 20 */
- + float fresnel = fresnel_dielectric_cos(dot(m,I), 1.45f);
- float common = D * 0.25f / cosNO;
- - float out = G * common;
- + float out = fresnel * G * common;
- /* eq. 2 in distribution of visible normals sampling
- * pm = Dw = G1o * dot(m, I) * D / dot(N, I); */
- @@ -501,8 +503,9 @@ ccl_device int bsdf_microfacet_ggx_sample(KernelGlobals *kg, const ShaderClosure
- }
- /* see eval function for derivation */
- + float fresnel = fresnel_dielectric_cos(dot(m,I), 1.45f);
- float common = (G1o * D) * 0.25f / cosNO;
- - float out = G1i * common;
- + float out = fresnel * G1i * common;
- *pdf = common;
- *eval = make_float3(out, out, out);
Add Comment
Please, Sign In to add comment