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:
authorAntonio Vazquez <blendergit@gmail.com>2019-08-10 18:16:12 +0300
committerAntonio Vazquez <blendergit@gmail.com>2019-08-10 18:16:12 +0300
commit7029810b04c37e8dd0a7256047038fc6f8192309 (patch)
tree7410afe5d87124d5cf8fd36c3ed7165923c0be72 /source/blender/makesrna
parent745f773d92b6d1aa65154a899ba3a5293fa75d4d (diff)
GPencil: Add new Distance property to Simplify modifier
Before, the length variable was reused for Sample and Merge Simplify. Now, the Merge has its own distance property and variable in the modifier struct.
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/intern/rna_gpencil_modifier.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_gpencil_modifier.c b/source/blender/makesrna/intern/rna_gpencil_modifier.c
index 48ef4b6c29e..de24b5d3f4b 100644
--- a/source/blender/makesrna/intern/rna_gpencil_modifier.c
+++ b/source/blender/makesrna/intern/rna_gpencil_modifier.c
@@ -689,9 +689,16 @@ static void rna_def_modifier_gpencilsimplify(BlenderRNA *brna)
/* Sample */
prop = RNA_def_property(srna, "length", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "length");
- RNA_def_property_range(prop, 0, 10);
+ RNA_def_property_range(prop, 0, 10.0f);
RNA_def_property_ui_text(prop, "Length", "Length of each segment");
RNA_def_property_update(prop, 0, "rna_GpencilModifier_update");
+
+ /* Distance */
+ prop = RNA_def_property(srna, "distance", PROP_FLOAT, PROP_NONE);
+ RNA_def_property_float_sdna(prop, NULL, "distance");
+ RNA_def_property_range(prop, 0, 100.0f);
+ RNA_def_property_ui_text(prop, "Distance", "Distance between vertex");
+ RNA_def_property_update(prop, 0, "rna_GpencilModifier_update");
}
static void rna_def_modifier_gpencilthick(BlenderRNA *brna)