[Bf-blender-cvs] [a84e67adaf5] temp-sculpt-normals-masking: temp-sculpt-normals-masking: Make requested patch changes
Joseph Eagar
noreply at git.blender.org
Tue Sep 27 19:47:17 CEST 2022
Commit: a84e67adaf5475399ff03bfbc6d6325de7d271c8
Author: Joseph Eagar
Date: Tue Sep 27 10:46:57 2022 -0700
Branches: temp-sculpt-normals-masking
https://developer.blender.org/rBa84e67adaf5475399ff03bfbc6d6325de7d271c8
temp-sculpt-normals-masking: Make requested patch changes
===================================================================
M source/blender/editors/sculpt_paint/sculpt_automasking.cc
M source/blender/editors/sculpt_paint/sculpt_transform.c
M source/blender/makesrna/intern/rna_brush.c
M source/blender/makesrna/intern/rna_sculpt_paint.c
===================================================================
diff --git a/source/blender/editors/sculpt_paint/sculpt_automasking.cc b/source/blender/editors/sculpt_paint/sculpt_automasking.cc
index 895f66e97f5..b2a8faa96ba 100644
--- a/source/blender/editors/sculpt_paint/sculpt_automasking.cc
+++ b/source/blender/editors/sculpt_paint/sculpt_automasking.cc
@@ -516,7 +516,10 @@ void sculpt_normal_occlusion_automasking_fill(AutomaskingCache *automasking,
f *= automasking_view_normal_factor(automasking, ss, vertex, &nodedata);
}
- *(uchar *)SCULPT_vertex_attr_get(vertex, ss->attrs.stroke_id) = ss->stroke_id;
+ if (ss->attrs.stroke_id) {
+ *(uchar *)SCULPT_vertex_attr_get(vertex, ss->attrs.stroke_id) = ss->stroke_id;
+ }
+
*(float *)SCULPT_vertex_attr_get(vertex, ss->attrs.automasking_factor) = f;
}
}
diff --git a/source/blender/editors/sculpt_paint/sculpt_transform.c b/source/blender/editors/sculpt_paint/sculpt_transform.c
index 7fe50398ec8..f841cd14386 100644
--- a/source/blender/editors/sculpt_paint/sculpt_transform.c
+++ b/source/blender/editors/sculpt_paint/sculpt_transform.c
@@ -67,7 +67,6 @@ void ED_sculpt_init_transform(struct bContext *C, Object *ob, const int mval[2],
SCULPT_vertex_random_access_ensure(ss);
- /* TODO: make the area normal pixel radius user-configurable? */
SCULPT_filter_cache_init(C, ob, sd, SCULPT_UNDO_COORDS, mval, 5.0);
if (sd->transform_mode == SCULPT_TRANSFORM_MODE_RADIUS_ELASTIC) {
diff --git a/source/blender/makesrna/intern/rna_brush.c b/source/blender/makesrna/intern/rna_brush.c
index 0e29b23f937..00421dcd97a 100644
--- a/source/blender/makesrna/intern/rna_brush.c
+++ b/source/blender/makesrna/intern/rna_brush.c
@@ -3211,7 +3211,7 @@ static void rna_def_brush(BlenderRNA *brna)
prop, NULL, "automasking_flags", BRUSH_AUTOMASKING_BRUSH_NORMAL);
RNA_def_property_ui_text(prop,
"Area Normal",
- "Only include vertices with similar normal to initial brush dab");
+ "Affect only vertices with a similar normal to where the stroke starts");
RNA_def_property_update(prop, 0, "rna_Brush_update");
prop = RNA_def_property(srna, "use_automasking_view_normal", PROP_BOOLEAN, PROP_NONE);
@@ -3219,12 +3219,12 @@ static void rna_def_brush(BlenderRNA *brna)
prop, NULL, "automasking_flags", BRUSH_AUTOMASKING_VIEW_NORMAL);
RNA_def_property_ui_text(prop,
"View Normal",
- "Mask back facing vertices");
+ "Affect only vertices with a normal that faces the viewer");
RNA_def_property_update(prop, 0, "rna_Brush_update");
prop = RNA_def_property(srna, "use_automasking_view_occlusion", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "automasking_flags", BRUSH_AUTOMASKING_VIEW_OCCLUSION);
- RNA_def_property_ui_text(prop, "Occlusion", "Mask occluded vertices");
+ RNA_def_property_ui_text(prop, "Occlusion", "Only affect vertices that are not occluded by other faces. (Slower performance)");
RNA_def_property_update(prop, 0, "rna_Brush_update");
diff --git a/source/blender/makesrna/intern/rna_sculpt_paint.c b/source/blender/makesrna/intern/rna_sculpt_paint.c
index 4de31f52c08..ffa0dfe35a9 100644
--- a/source/blender/makesrna/intern/rna_sculpt_paint.c
+++ b/source/blender/makesrna/intern/rna_sculpt_paint.c
@@ -938,7 +938,7 @@ static void rna_def_sculpt(BlenderRNA *brna)
RNA_def_property_range(prop, 0.0001f, M_PI);
RNA_def_property_ui_text(prop,
"Area Normal Limit",
- "Angular range that will be affected.");
+ "The range of angles that will be affected");
RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
prop = RNA_def_property(srna, "automasking_start_normal_falloff", PROP_FLOAT, PROP_FACTOR);
@@ -956,7 +956,7 @@ static void rna_def_sculpt(BlenderRNA *brna)
RNA_def_property_range(prop, 0.0001f, M_PI);
RNA_def_property_ui_text(prop,
"View Normal Limit",
- "Angular range that will be affected.");
+ "The range of angles that will be affected");
RNA_def_property_update(prop, NC_SCENE | ND_TOOLSETTINGS, NULL);
prop = RNA_def_property(srna, "automasking_view_normal_falloff", PROP_FLOAT, PROP_FACTOR);
More information about the Bf-blender-cvs
mailing list