diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-08-19 18:58:58 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-08-19 18:58:58 +0400 |
commit | 7bc87a372e40b6adc852d42c60ea6aca55aaa7fb (patch) | |
tree | cc85f43f178514987594e642e29c8dd01fba6626 /intern | |
parent | 2184ac8c9d878cbf507437a08cc824eed536540b (diff) |
Fix T40962: Ashikhmen Shirley shader fireflies
Diffstat (limited to 'intern')
-rw-r--r-- | intern/cycles/kernel/closure/bsdf_ashikhmin_shirley.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/intern/cycles/kernel/closure/bsdf_ashikhmin_shirley.h b/intern/cycles/kernel/closure/bsdf_ashikhmin_shirley.h index 6a5d0410e01..ad7864cb8ea 100644 --- a/intern/cycles/kernel/closure/bsdf_ashikhmin_shirley.h +++ b/intern/cycles/kernel/closure/bsdf_ashikhmin_shirley.h @@ -77,7 +77,7 @@ ccl_device float3 bsdf_ashikhmin_shirley_eval_reflect(const ShaderClosure *sc, c NdotI = fmaxf(NdotI, 1e-6f); NdotO = fmaxf(NdotO, 1e-6f); float3 H = normalize(omega_in + I); - float HdotI = fmaxf(dot(H, I), 1e-6f); + float HdotI = fmaxf(fabsf(dot(H, I)), 1e-6f); float HdotN = fmaxf(dot(H, N), 1e-6f); float pump = 1.0f / fmaxf(1e-6f, (HdotI*fmaxf(NdotO, NdotI))); /* pump from original paper (first derivative disc., but cancels the HdotI in the pdf nicely) */ |