diff options
author | Jacques Lucke <jacques@blender.org> | 2021-02-10 14:48:17 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2021-02-10 14:48:17 +0300 |
commit | d76890bfb0bba78d7ad617c5ad8fb284cd9814d4 (patch) | |
tree | 8128972cd66aa451883a17a5c5a4eca5829f645b /source | |
parent | f617782fc101c844959c799ad584a37f3b6e523a (diff) |
Fix T85492: fix check if object has visible instances
Without this, `OB_VISIBLE_INSTANCES` would be added to `visibility` incorrectly,
leading to unexpected visibility changes down the line.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/object.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c index 155508e9caa..70af46569a8 100644 --- a/source/blender/blenkernel/intern/object.c +++ b/source/blender/blenkernel/intern/object.c @@ -1957,7 +1957,8 @@ int BKE_object_visibility(const Object *ob, const int dag_eval_mode) visibility |= OB_VISIBLE_INSTANCES; } - if (ob->runtime.geometry_set_eval != NULL) { + if (ob->runtime.geometry_set_eval != NULL && + BKE_geometry_set_has_instances(ob->runtime.geometry_set_eval)) { visibility |= OB_VISIBLE_INSTANCES; } |