diff options
author | Pablo Dobarro <pablodp606@gmail.com> | 2020-07-08 00:01:51 +0300 |
---|---|---|
committer | Pablo Dobarro <pablodp606@gmail.com> | 2020-07-09 18:50:10 +0300 |
commit | 1fb667da013f19124eb4440411c28996d97f67f8 (patch) | |
tree | 7881f630d1c03d3f5ed502a70fc321028673d721 /source/blender/blenkernel/intern/pbvh.c | |
parent | e5ebaa9fd6ee227427e19eafd47ae087ab95eae1 (diff) |
Fix wrong upate flag when updating the PBVH visibility
This function was using the wrong flag to update the visibility state of
the nodes, so I assume that most of the partially visible optimizations
were not working.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D8243
Diffstat (limited to 'source/blender/blenkernel/intern/pbvh.c')
-rw-r--r-- | source/blender/blenkernel/intern/pbvh.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/pbvh.c b/source/blender/blenkernel/intern/pbvh.c index 8d7dabf9859..77ff469a012 100644 --- a/source/blender/blenkernel/intern/pbvh.c +++ b/source/blender/blenkernel/intern/pbvh.c @@ -1542,7 +1542,7 @@ static void pbvh_update_visibility_task_cb(void *__restrict userdata, PBVHUpdateData *data = userdata; PBVH *pbvh = data->pbvh; PBVHNode *node = data->nodes[n]; - if (node->flag & PBVH_UpdateMask) { + if (node->flag & PBVH_UpdateVisibility) { switch (BKE_pbvh_type(pbvh)) { case PBVH_FACES: pbvh_faces_node_visibility_update(pbvh, node); @@ -1554,7 +1554,7 @@ static void pbvh_update_visibility_task_cb(void *__restrict userdata, pbvh_bmesh_node_visibility_update(node); break; } - node->flag &= ~PBVH_UpdateMask; + node->flag &= ~PBVH_UpdateVisibility; } } |