diff options
Diffstat (limited to 'source/blender/blenkernel/intern/object_update.c')
-rw-r--r-- | source/blender/blenkernel/intern/object_update.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/object_update.c b/source/blender/blenkernel/intern/object_update.c index 2bb06c86120..b682e233888 100644 --- a/source/blender/blenkernel/intern/object_update.c +++ b/source/blender/blenkernel/intern/object_update.c @@ -31,6 +31,7 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" +#include "BLI_threads.h" #include "BLI_math.h" #include "BKE_animsys.h" @@ -396,7 +397,16 @@ void BKE_object_data_select_update(Depsgraph *depsgraph, ID *object_data) void BKE_object_select_update(Depsgraph *depsgraph, Object *object) { DEG_debug_print_eval(depsgraph, __func__, object->id.name, object); - BKE_object_data_select_update(depsgraph, object->data); + if (!object->runtime.is_mesh_eval_owned) { + Mesh *mesh_input = object->runtime.mesh_orig; + Mesh_Runtime *mesh_runtime = &mesh_input->runtime; + BLI_mutex_lock(mesh_runtime->eval_mutex); + BKE_object_data_select_update(depsgraph, object->data); + BLI_mutex_unlock(mesh_runtime->eval_mutex); + } + else { + BKE_object_data_select_update(depsgraph, object->data); + } } void BKE_object_eval_eval_base_flags(Depsgraph *depsgraph, |