Skip to content
This repository has been archived by the owner on Oct 7, 2021. It is now read-only.

Commit

Permalink
mgear_core: applyop stretch: component using squash stretch solver ex…
Browse files Browse the repository at this point in the history
…plodes when max stretch above 1.5 Fixes #30
  • Loading branch information
miquelcampos committed Apr 3, 2019
1 parent fc37064 commit ebad733
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion scripts/mgear/core/applyop.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
#############################################
import pymel.core as pm
from pymel.core import datatypes
from mgear.core import node as nod

#############################################
# BUILT IN NODES
Expand Down Expand Up @@ -640,7 +641,11 @@ def gear_squashstretch2_op(out,
# osx
# Also helper connection for scale compensation (scaleComp)
mult_node = pm.createNode("multiplyDivide")
pm.connectAttr(node + ".output", mult_node + ".input1")
clamp_node = nod.createClampNode(
[node.outputX, node.outputY, node.outputZ],
[0.001, 0.001, 0.001],
[100000, 100000, 100000])
pm.connectAttr(clamp_node + ".output", mult_node + ".input1")
for axis in "XYZ":
pm.connectAttr(mult_node + ".output%s" % axis, out + ".scale%s" % axis)
if scaleComp:
Expand Down

0 comments on commit ebad733

Please sign in to comment.