Fix T40997, artifacts when unhiding part of the mesh in dyntopo.
Tagging a face as hidden should not be done only when hiding.
This commit is contained in:
parent
b617d6d5e6
commit
f5caab2cf7
Notes:
blender-bot
2023-02-14 10:22:24 +01:00
Referenced by issue #40997, Artifacts while unhiding part of mesh while dyntopo
|
@ -252,14 +252,14 @@ static void partialvis_update_bmesh_verts(BMesh *bm,
|
|||
}
|
||||
}
|
||||
|
||||
static void partialvis_update_bmesh_faces(GSet *faces, PartialVisAction action)
|
||||
static void partialvis_update_bmesh_faces(GSet *faces)
|
||||
{
|
||||
GSetIterator gs_iter;
|
||||
|
||||
GSET_ITER (gs_iter, faces) {
|
||||
BMFace *f = BLI_gsetIterator_getKey(&gs_iter);
|
||||
|
||||
if ((action == PARTIALVIS_HIDE) && paint_is_bmesh_face_hidden(f))
|
||||
if (paint_is_bmesh_face_hidden(f))
|
||||
BM_elem_flag_enable(f, BM_ELEM_HIDDEN);
|
||||
else
|
||||
BM_elem_flag_disable(f, BM_ELEM_HIDDEN);
|
||||
|
@ -301,7 +301,7 @@ static void partialvis_update_bmesh(Object *ob,
|
|||
&any_visible);
|
||||
|
||||
/* finally loop over node faces and tag the ones that are fully hidden */
|
||||
partialvis_update_bmesh_faces(faces, action);
|
||||
partialvis_update_bmesh_faces(faces);
|
||||
|
||||
if (any_changed) {
|
||||
BKE_pbvh_node_mark_rebuild_draw(node);
|
||||
|
|
Loading…
Reference in New Issue