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:
Diffstat (limited to 'source/blender/draw/intern/draw_cache_impl_mesh.c')
-rw-r--r--source/blender/draw/intern/draw_cache_impl_mesh.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/draw/intern/draw_cache_impl_mesh.c b/source/blender/draw/intern/draw_cache_impl_mesh.c
index e4aec17eb69..917216b92e6 100644
--- a/source/blender/draw/intern/draw_cache_impl_mesh.c
+++ b/source/blender/draw/intern/draw_cache_impl_mesh.c
@@ -883,6 +883,11 @@ static bool mesh_batch_cache_valid(Object *object, Mesh *me)
if (cache->pbvh_is_drawing != BKE_pbvh_is_drawing(object->sculpt->pbvh)) {
return false;
}
+
+ if (BKE_pbvh_is_drawing(object->sculpt->pbvh) &&
+ BKE_pbvh_draw_cache_invalid(object->sculpt->pbvh)) {
+ return false;
+ }
}
if (cache->is_editmode != (me->edit_mesh != NULL)) {