Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2017-03-13 11:55:18 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2017-03-13 11:57:25 +0300
commit8794a43b688f513d8fac317c2fd2d0bd82c26168 (patch)
treeaaf3943e311f6884e3ff4b8cedc44f98fd5ab11d /intern/cycles/kernel/closure/bsdf_microfacet.h
parente8021f5e3bd41d2447c35d999aef1a7588bc039a (diff)
Cycles: Make MESA compiler more happy
While this compiler is not officially supported yet, getting it to work is a nice thing because more and more AMD cards will fall under MESA driver. It's also nice to use explicit comparison with NULL, which makes it more clear whether variable is a boolean or pointer. Even Rust enforces this! Patch by Ian Bruce with own modifications.
Diffstat (limited to 'intern/cycles/kernel/closure/bsdf_microfacet.h')
-rw-r--r--intern/cycles/kernel/closure/bsdf_microfacet.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/intern/cycles/kernel/closure/bsdf_microfacet.h b/intern/cycles/kernel/closure/bsdf_microfacet.h
index 4a1316fd2a9..1c7b3eb9ddd 100644
--- a/intern/cycles/kernel/closure/bsdf_microfacet.h
+++ b/intern/cycles/kernel/closure/bsdf_microfacet.h
@@ -266,7 +266,7 @@ ccl_device bool bsdf_microfacet_merge(const ShaderClosure *a, const ShaderClosur
(bsdf_a->alpha_y == bsdf_b->alpha_y) &&
(isequal_float3(bsdf_a->T, bsdf_b->T)) &&
(bsdf_a->ior == bsdf_b->ior) &&
- ((!bsdf_a->extra && !bsdf_b->extra) ||
+ ((bsdf_a->extra == NULL && bsdf_b->extra == NULL) ||
((bsdf_a->extra && bsdf_b->extra) &&
(isequal_float3(bsdf_a->extra->color, bsdf_b->extra->color))));
}