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:
authorJacques Lucke <jacques@blender.org>2021-11-10 15:38:07 +0300
committerJacques Lucke <jacques@blender.org>2021-11-10 15:38:07 +0300
commit47b8baa5c4e5b713d33e3925df9d55b882ae2a27 (patch)
tree2557e4a397f32dfd342f5d1ee7881425fef0c0f9 /intern/cycles/blender/sync.h
parentaa2f6e59770896a981831c432667bbf58e232ce2 (diff)
Fix T92864: curve object does not sync correctly in cycles
The issue was that the `object_is_geometry` method was used in two different contexts that expected the function to behave differently. So a recent change that fixed `object_is_geometry` for one context, broke it for the other context. The two contexts are: * Check if a "real" object can contain a geometry to check if it has to be tagged for sync after an update. * Check if an object/instance actually is a geometry that cycles can work with. I created a new `object_can_have_geometry` method for the first use case, instead of trying to adapt the existing object_is_geometry method to serve both uses. Additionally, I changed it so that a BObjectInfo is passed into `object_is_geometry` to make it more explicit when this method is supposed to be used. Differential Revision: https://developer.blender.org/D13135
Diffstat (limited to 'intern/cycles/blender/sync.h')
-rw-r--r--intern/cycles/blender/sync.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/intern/cycles/blender/sync.h b/intern/cycles/blender/sync.h
index 7e5d0324ca9..98197564bec 100644
--- a/intern/cycles/blender/sync.h
+++ b/intern/cycles/blender/sync.h
@@ -208,7 +208,8 @@ class BlenderSync {
/* util */
void find_shader(BL::ID &id, array<Node *> &used_shaders, Shader *default_shader);
bool BKE_object_is_modified(BL::Object &b_ob);
- bool object_is_geometry(BL::Object &b_ob);
+ bool object_is_geometry(BObjectInfo &b_ob_info);
+ bool object_can_have_geometry(BL::Object &b_ob);
bool object_is_light(BL::Object &b_ob);
/* variables */