Fix #141247: Assert while using sculpt filter tools
Introduced with 906a27bdb2
Pull Request: https://projects.blender.org/blender/blender/pulls/141248
This commit is contained in:
@@ -2431,7 +2431,9 @@ static wmOperatorStatus sculpt_cloth_filter_invoke(bContext *C,
|
||||
RNA_float_get(op->ptr, "area_normal_radius"),
|
||||
RNA_float_get(op->ptr, "strength"));
|
||||
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
if (auto_mask::is_enabled(sd, ob, nullptr)) {
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
}
|
||||
|
||||
const float cloth_mass = RNA_float_get(op->ptr, "cloth_mass");
|
||||
const float cloth_damping = RNA_float_get(op->ptr, "cloth_damping");
|
||||
|
||||
@@ -509,7 +509,9 @@ static int sculpt_color_filter_init(bContext *C, wmOperator *op)
|
||||
const SculptSession &ss = *ob.sculpt;
|
||||
filter::Cache *filter_cache = ss.filter_cache;
|
||||
filter_cache->active_face_set = SCULPT_FACE_SET_NONE;
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
if (auto_mask::is_enabled(sd, ob, nullptr)) {
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
}
|
||||
|
||||
return OPERATOR_PASS_THROUGH;
|
||||
}
|
||||
|
||||
@@ -2439,7 +2439,9 @@ static wmOperatorStatus sculpt_mesh_filter_start(bContext *C, wmOperator *op)
|
||||
|
||||
filter::Cache *filter_cache = ss.filter_cache;
|
||||
filter_cache->active_face_set = SCULPT_FACE_SET_NONE;
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
if (auto_mask::is_enabled(sd, ob, nullptr)) {
|
||||
auto_mask::filter_cache_ensure(*depsgraph, sd, ob);
|
||||
}
|
||||
|
||||
sculpt_filter_specific_init(*depsgraph, filter_type, op, ob);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user