diff options
author | Joshua Leung <aligorith@gmail.com> | 2015-01-13 08:06:53 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2015-01-13 08:06:53 +0300 |
commit | f0361fcf54e8d15790e2bad5c7402f6af3c24083 (patch) | |
tree | 0d396f70b1a96504ba112bf251c417ceb513bd27 /release/scripts/startup/bl_ui/properties_constraint.py | |
parent | f453df5b0382a895edb23753a73b6d9b9cbea6ed (diff) |
Pataz-Gooseberry Request: Limits on Volume Preservation for Spline IK
This commit adds a new type of volume preservation mode to Spline IK
which makes it possible to set limits on the minimum and maximum
scaling of bone "fatness".
* The old volume preseving mode has been kept but renamed, to avoid
breaking old rigs. "Volume Presevation" uses the new method, while
"Inverse Preservation" is the old one.
* The code and settings for this new xz scale mode are directly lifted
from the improved Stretch To constraint
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_constraint.py')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_constraint.py | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/release/scripts/startup/bl_ui/properties_constraint.py b/release/scripts/startup/bl_ui/properties_constraint.py index e6b62cae6ef..0c5aae1de2f 100644 --- a/release/scripts/startup/bl_ui/properties_constraint.py +++ b/release/scripts/startup/bl_ui/properties_constraint.py @@ -768,9 +768,27 @@ class ConstraintButtonsPanel(): col = layout.column() col.label(text="Chain Scaling:") col.prop(con, "use_y_stretch") - col.prop(con, "xz_scale_mode") col.prop(con, "use_curve_radius") + layout.prop(con, "xz_scale_mode") + + if con.xz_scale_mode == 'VOLUME_PRESERVE': + layout.prop(con, "bulge", text="Volume Variation") + split = layout.split() + col = split.column(align=True) + col.prop(con, "use_bulge_min", text="Volume Min") + sub = col.column() + sub.active = con.use_bulge_min + sub.prop(con, "bulge_min", text="") + col = split.column(align=True) + col.prop(con, "use_bulge_max", text="Volume Max") + sub = col.column() + sub.active = con.use_bulge_max + sub.prop(con, "bulge_max", text="") + col = layout.column() + col.active = con.use_bulge_min or con.use_bulge_max + col.prop(con, "bulge_smooth", text="Smooth") + def PIVOT(self, context, layout, con): self.target_template(layout, con) |