Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2022-09-16 06:54:41 +0300
committerHans Goudey <h.goudey@me.com>2022-09-16 06:54:51 +0300
commita231637faeef8f562d40893b7131db3e668a317c (patch)
treefca6b90fe56d76a4df4d86fcdb5924f22855c953
parent72253f427d4c3b54166ecdc00ab505909c180ec4 (diff)
Sculpt: Respect hiding when creating face sets from loose parts
Different areas of the mesh can be "loose parts" visually when separated by hidden areas. This is consistent with other areas of sculpt mode that also treat hidden areas differently.
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_face_set.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt_face_set.c b/source/blender/editors/sculpt_paint/sculpt_face_set.c
index 90b92845b09..091d9fbffe8 100644
--- a/source/blender/editors/sculpt_paint/sculpt_face_set.c
+++ b/source/blender/editors/sculpt_paint/sculpt_face_set.c
@@ -517,12 +517,12 @@ typedef bool (*face_sets_flood_fill_test)(
BMesh *bm, BMFace *from_f, BMEdge *from_e, BMFace *to_f, const float threshold);
static bool sculpt_face_sets_init_loose_parts_test(BMesh *UNUSED(bm),
- BMFace *UNUSED(from_f),
+ BMFace *from_f,
BMEdge *UNUSED(from_e),
- BMFace *UNUSED(to_f),
+ BMFace *to_f,
const float UNUSED(threshold))
{
- return true;
+ return BM_elem_flag_test(from_f, BM_ELEM_HIDDEN) == BM_elem_flag_test(to_f, BM_ELEM_HIDDEN);
}
static bool sculpt_face_sets_init_normals_test(