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:
authorCampbell Barton <ideasman42@gmail.com>2020-08-06 02:38:25 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-08-06 02:38:25 +0300
commit85ddba475baec0737367069a019e0d2a98dacbd7 (patch)
tree83252ce67f7fb5445894ed4bc16d6909b9f9fff6
parent675700d94892832b264f8b37d3d907c527a83cf5 (diff)
Cleanup: no need for plural for term 'collision'
-rw-r--r--release/scripts/startup/bl_ui/properties_paint_common.py2
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_cloth.c9
-rw-r--r--source/blender/makesdna/DNA_brush_types.h2
-rw-r--r--source/blender/makesrna/intern/rna_brush.c7
4 files changed, 12 insertions, 8 deletions
diff --git a/release/scripts/startup/bl_ui/properties_paint_common.py b/release/scripts/startup/bl_ui/properties_paint_common.py
index 8afd47f5da6..ee62a1115e3 100644
--- a/release/scripts/startup/bl_ui/properties_paint_common.py
+++ b/release/scripts/startup/bl_ui/properties_paint_common.py
@@ -667,7 +667,7 @@ def brush_settings(layout, context, brush, popover=False):
layout.prop(brush, "cloth_damping")
layout.prop(brush, "cloth_constraint_softbody_strength")
layout.separator()
- layout.prop(brush, "use_cloth_collisions")
+ layout.prop(brush, "use_cloth_collision")
layout.separator()
elif sculpt_tool == 'SCRAPE':
diff --git a/source/blender/editors/sculpt_paint/sculpt_cloth.c b/source/blender/editors/sculpt_paint/sculpt_cloth.c
index c6feef0808c..cfcd34ce3a5 100644
--- a/source/blender/editors/sculpt_paint/sculpt_cloth.c
+++ b/source/blender/editors/sculpt_paint/sculpt_cloth.c
@@ -907,7 +907,11 @@ void SCULPT_do_cloth_brush(Sculpt *sd, Object *ob, PBVHNode **nodes, int totnode
if (SCULPT_stroke_is_first_brush_step(ss->cache) || !ss->cache->cloth_sim) {
const bool is_cloth_deform_brush = SCULPT_is_cloth_deform_brush(brush);
ss->cache->cloth_sim = cloth_brush_simulation_create(
- ss, brush, brush->cloth_mass, brush->cloth_damping, brush->flag2 & BRUSH_CLOTH_USE_COLLISIONS);
+ ss,
+ brush,
+ brush->cloth_mass,
+ brush->cloth_damping,
+ (brush->flag2 & BRUSH_CLOTH_USE_COLLISION));
for (int i = 0; i < totverts; i++) {
copy_v3_v3(ss->cache->cloth_sim->last_iteration_pos[i], SCULPT_vertex_co_get(ss, i));
copy_v3_v3(ss->cache->cloth_sim->init_pos[i], SCULPT_vertex_co_get(ss, i));
@@ -1182,7 +1186,8 @@ static int sculpt_cloth_filter_invoke(bContext *C, wmOperator *op, const wmEvent
const float cloth_mass = RNA_float_get(op->ptr, "cloth_mass");
const float cloth_damping = RNA_float_get(op->ptr, "cloth_damping");
const bool use_collisions = RNA_boolean_get(op->ptr, "use_collisions");
- ss->filter_cache->cloth_sim = cloth_brush_simulation_create(ss, NULL, cloth_mass, cloth_damping, use_collisions);
+ ss->filter_cache->cloth_sim = cloth_brush_simulation_create(
+ ss, NULL, cloth_mass, cloth_damping, use_collisions);
copy_v3_v3(ss->filter_cache->cloth_sim_pinch_point, SCULPT_active_vertex_co_get(ss));
diff --git a/source/blender/makesdna/DNA_brush_types.h b/source/blender/makesdna/DNA_brush_types.h
index 72f205685b9..7b3e9dabe9f 100644
--- a/source/blender/makesdna/DNA_brush_types.h
+++ b/source/blender/makesdna/DNA_brush_types.h
@@ -740,7 +740,7 @@ typedef enum eBrushFlags2 {
BRUSH_USE_CONNECTED_ONLY = (1 << 3),
BRUSH_CLOTH_PIN_SIMULATION_BOUNDARY = (1 << 4),
BRUSH_POSE_USE_LOCK_ROTATION = (1 << 5),
- BRUSH_CLOTH_USE_COLLISIONS = (1 << 6),
+ BRUSH_CLOTH_USE_COLLISION = (1 << 6),
} eBrushFlags2;
typedef enum {
diff --git a/source/blender/makesrna/intern/rna_brush.c b/source/blender/makesrna/intern/rna_brush.c
index ccd2919ab98..d20cec518bc 100644
--- a/source/blender/makesrna/intern/rna_brush.c
+++ b/source/blender/makesrna/intern/rna_brush.c
@@ -2824,10 +2824,9 @@ static void rna_def_brush(BlenderRNA *brna)
"create a softer transitionwith with unnafected areas");
RNA_def_property_update(prop, 0, "rna_Brush_update");
- prop = RNA_def_property(srna, "use_cloth_collisions", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "flag2", BRUSH_CLOTH_USE_COLLISIONS);
- RNA_def_property_ui_text(
- prop, "Enable Collisions", "Collide with objects during the simulation");
+ prop = RNA_def_property(srna, "use_cloth_collision", PROP_BOOLEAN, PROP_NONE);
+ RNA_def_property_boolean_sdna(prop, NULL, "flag2", BRUSH_CLOTH_USE_COLLISION);
+ RNA_def_property_ui_text(prop, "Enable Collision", "Collide with objects during the simulation");
RNA_def_property_update(prop, 0, "rna_Brush_update");
prop = RNA_def_property(srna, "invert_to_scrape_fill", PROP_BOOLEAN, PROP_NONE);