diff options
author | Pablo Dobarro <pablodp606@gmail.com> | 2020-05-19 02:04:37 +0300 |
---|---|---|
committer | Pablo Dobarro <pablodp606@gmail.com> | 2020-05-25 18:35:39 +0300 |
commit | 6d4dc22e17a7b2bb22495602a8f64cd6c00162d3 (patch) | |
tree | 64eeca24bcb58e693519af8232c1d25797a9a344 /source/blender/makesrna/intern/rna_brush.c | |
parent | 28d81f7b24283e31fc3a636dc30f37d57d0e3c58 (diff) |
Sculpt: Pose Brush Scale/Transform deform mode
This is an alternative deformation brush for the Pose Brush intended
quickly change the proportions of the mesh. The regular mode scales
using the segment's origin as a pivot. The inverted mode drags the
entire segment using the grab delta.
The only difference with the regular pose brush is that it is not
compatible with IK, so the option is disabled and set to 1 segment. The
rest of the options should work as expected.
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D7374
Diffstat (limited to 'source/blender/makesrna/intern/rna_brush.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_brush.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_brush.c b/source/blender/makesrna/intern/rna_brush.c index d3b607fcb76..9e78eec9c25 100644 --- a/source/blender/makesrna/intern/rna_brush.c +++ b/source/blender/makesrna/intern/rna_brush.c @@ -1960,6 +1960,12 @@ static void rna_def_brush(BlenderRNA *brna) {0, NULL, 0, NULL, NULL}, }; + static const EnumPropertyItem brush_pose_deform_type_items[] = { + {BRUSH_POSE_DEFORM_ROTATE_TWIST, "ROTATE_TWIST", 0, "Rotate/Twist", ""}, + {BRUSH_POSE_DEFORM_SCALE_TRASLATE, "SCALE_TRANSLATE", 0, "Scale/Translate", ""}, + {0, NULL, 0, NULL, NULL}, + }; + static const EnumPropertyItem brush_pose_origin_type_items[] = { {BRUSH_POSE_ORIGIN_TOPOLOGY, "TOPOLOGY", @@ -2095,6 +2101,11 @@ static void rna_def_brush(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Deformation", "Deformation type that is used in the brush"); RNA_def_property_update(prop, 0, "rna_Brush_update"); + prop = RNA_def_property(srna, "pose_deform_type", PROP_ENUM, PROP_NONE); + RNA_def_property_enum_items(prop, brush_pose_deform_type_items); + RNA_def_property_ui_text(prop, "Deformation", "Deformation type that is used in the brush"); + RNA_def_property_update(prop, 0, "rna_Brush_update"); + prop = RNA_def_property(srna, "pose_origin_type", PROP_ENUM, PROP_NONE); RNA_def_property_enum_items(prop, brush_pose_origin_type_items); RNA_def_property_ui_text(prop, |