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
This commit is contained in:
@@ -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;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user