From cc0e015a3523cf4e5292080d08ba3d48451f5f6b Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Tue, 19 Mar 2024 16:55:21 +0100 Subject: [PATCH] Fix #119177: False positive dyntopo attribute detection warning ".sculpt_mask" is handled as a special case for dynamic topology but wasn't detected that way in the warning. Pull Request: https://projects.blender.org/blender/blender/pulls/119665 --- source/blender/editors/sculpt_paint/sculpt_dyntopo.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/blender/editors/sculpt_paint/sculpt_dyntopo.cc b/source/blender/editors/sculpt_paint/sculpt_dyntopo.cc index e9a734b49a1..a2548e31c94 100644 --- a/source/blender/editors/sculpt_paint/sculpt_dyntopo.cc +++ b/source/blender/editors/sculpt_paint/sculpt_dyntopo.cc @@ -293,11 +293,12 @@ static int dyntopo_warning_popup(bContext *C, wmOperatorType *ot, enum WarnFlag static bool dyntopo_supports_layer(const CustomDataLayer &layer) { + if (layer.type == CD_PROP_FLOAT && STREQ(layer.name, ".sculpt_mask")) { + return true; + } if (CD_TYPE_AS_MASK(layer.type) & CD_MASK_PROP_ALL) { - /* Some data is stored as generic attributes on #Mesh but in flags or fields on #BMesh. */ return BM_attribute_stored_in_bmesh_builtin(layer.name); } - /* Some layers just encode #Mesh topology or are handled as special cases for dyntopo. */ return ELEM(layer.type, CD_ORIGINDEX); }