From 96f303392be1b8f87a00c0217c459a8731f9f792 Mon Sep 17 00:00:00 2001 From: Antony Riakiotakis Date: Thu, 29 May 2014 05:22:44 +0300 Subject: Fix T40381 and revert previous commit. Looks like the normal update flag is used internally in the modifier itself. So as a workaround just pass normal update to the nodes when flood filling --- source/blender/blenkernel/intern/pbvh.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'source/blender/blenkernel/intern/pbvh.c') diff --git a/source/blender/blenkernel/intern/pbvh.c b/source/blender/blenkernel/intern/pbvh.c index a60f7326b2b..9bffdd8a4e6 100644 --- a/source/blender/blenkernel/intern/pbvh.c +++ b/source/blender/blenkernel/intern/pbvh.c @@ -948,13 +948,8 @@ static void pbvh_update_normals(PBVH *bvh, PBVHNode **nodes, return; } - if (bvh->type != PBVH_FACES) { - /* make sure we clean up the flag! */ - for (n = 0; n < totnode; n++) { - nodes[n]->flag &= ~PBVH_UpdateNormals; - } + if (bvh->type != PBVH_FACES) return; - } /* could be per node to save some memory, but also means * we have to store for each vertex which node it is in */ @@ -1334,6 +1329,12 @@ void BKE_pbvh_node_mark_redraw(PBVHNode *node) node->flag |= PBVH_UpdateDrawBuffers | PBVH_UpdateRedraw; } +void BKE_pbvh_node_mark_normals_update(PBVHNode *node) +{ + node->flag |= PBVH_UpdateNormals; +} + + void BKE_pbvh_node_fully_hidden_set(PBVHNode *node, int fully_hidden) { BLI_assert(node->flag & PBVH_Leaf); -- cgit v1.2.3