From f408531b9bc7994c4b14728fe03068c19e4cef33 Mon Sep 17 00:00:00 2001 From: Sean Kim Date: Mon, 28 Oct 2024 22:52:40 +0100 Subject: [PATCH] Fix #129448: Undoing face set changes produces artifacts on dense mesh Introduced in 60ab232afbec7b0aed0e5389ea4c97d9b7f5797a An incorrect subset of nodes was calculated as the code prior to this commit was inspecting vertex indices instead of face indices. Pull Request: https://projects.blender.org/blender/blender/pulls/129487 --- source/blender/editors/sculpt_paint/sculpt_undo.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/editors/sculpt_paint/sculpt_undo.cc b/source/blender/editors/sculpt_paint/sculpt_undo.cc index 2e473c27233..aac7c50ef66 100644 --- a/source/blender/editors/sculpt_paint/sculpt_undo.cc +++ b/source/blender/editors/sculpt_paint/sculpt_undo.cc @@ -987,7 +987,7 @@ static void restore_list(bContext *C, Depsgraph *depsgraph, StepData &step_data) MutableSpan nodes = pbvh.nodes(); const IndexMask changed_nodes = IndexMask::from_predicate( node_mask, GrainSize(1), memory, [&](const int i) { - return indices_contain_true(modified_faces, nodes[i].all_verts()); + return indices_contain_true(modified_faces, nodes[i].faces()); }); pbvh.tag_face_sets_changed(changed_nodes); }