From 42e3eb8854c9495a197fd5fa9d0f7990c24cafa7 Mon Sep 17 00:00:00 2001 From: Jeroen Bakker Date: Wed, 9 Sep 2020 16:32:48 +0200 Subject: Fix T79038: Blender freezes on vertex paint on linked mesh data This change promotes the work-a-round to the current solution. There are options to solve this better, but needs more design. --- source/blender/draw/intern/draw_cache_impl_mesh.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'source/blender/draw') diff --git a/source/blender/draw/intern/draw_cache_impl_mesh.c b/source/blender/draw/intern/draw_cache_impl_mesh.c index c7ba707d403..d090832dc4b 100644 --- a/source/blender/draw/intern/draw_cache_impl_mesh.c +++ b/source/blender/draw/intern/draw_cache_impl_mesh.c @@ -1559,8 +1559,14 @@ void DRW_mesh_batch_cache_create_requested(struct TaskGraph *task_graph, scene, ts, use_hide); - /* TODO(jbakker): Work-around for threading issues in 2.90. See T79533, T79038. Needs to be - * solved or made permanent in 2.91. Underlying issue still needs to be researched. */ + + /* Ensure that all requested batches have finished. + * Ideally we want to remove this sync, but there are cases where this doesn't work. + * See T79038 for example. + * + * An idea to improve this is to separate the Object mode from the edit mode draw caches. And + * based on the mode the correct one will be updated. Other option is to look into using + * drw_batch_cache_generate_requested_delayed. */ BLI_task_graph_work_and_wait(task_graph); #ifdef DEBUG drw_mesh_batch_cache_check_available(task_graph, me); -- cgit v1.2.3