Skip to content

Commit

Permalink
EPIC_legs flip/twist issue and EPIC_arm tangent scale not 0.0 Fixes #99
Browse files Browse the repository at this point in the history
  • Loading branch information
miquelcampos committed Dec 14, 2022
1 parent 552850c commit 09628b5
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1001,10 +1001,10 @@ def addOperators(self):
attribute.setRotOrder(self.tws2_rot, "XYZ")
pm.connectAttr(dm_node + ".outputRotate", self.tws2_rot + ".rotate")

self.tws0_rot.setAttr("sx", 0.001)
self.tws2_rot.setAttr("sx", 0.001)
self.tws0_rot.setAttr("sx", 0.000001)
self.tws2_rot.setAttr("sx", 0.000001)

add_node = node.createAddNode(self.roundness_att, 0.0)
add_node = node.createAddNode(self.roundness_att, 0.000001)
pm.connectAttr(add_node + ".output", self.tws1_rot.attr("sx"))

pm.connectAttr(self.armpit_roll_att, self.tws0_rot + ".rotateX")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -297,9 +297,14 @@ def addObjects(self):
)

# tws_ref
t = transform.getRotationFromAxis(
datatypes.Vector(0, -1, 0), self.normal, "xz", self.negate
)
if self.up_axis == "y":
t = transform.getRotationFromAxis(
datatypes.Vector(0, -1, 0), self.normal, "xz", self.negate
)
else:
t = transform.getRotationFromAxis(
datatypes.Vector(0, 0, -1), self.normal, "xz", self.negate
)
t = transform.setMatrixPosition(t, self.guide.pos["ankle"])

# addind an npo parent transform to fix flip in Maya 2018.2
Expand Down Expand Up @@ -774,10 +779,10 @@ def addOperators(self):

applyop.oriCns(ori_ref, self.tws0_loc, maintainOffset=True)

self.tws0_loc.setAttr("sx", 0.001)
self.tws2_loc.setAttr("sx", 0.001)
self.tws0_loc.setAttr("sx", 0.000001)
self.tws2_loc.setAttr("sx", 0.000001)

add_node = node.createAddNode(self.roundness_att, 0.0)
add_node = node.createAddNode(self.roundness_att, 0.000001)
pm.connectAttr(add_node + ".output", self.tws1_rot.attr("sx"))

# Volume -------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1004,7 +1004,7 @@ def addOperators(self):
self.tws0_rot.setAttr("sx", 0.001)
self.tws2_rot.setAttr("sx", 0.001)

add_node = node.createAddNode(self.roundness_att, 0.0)
add_node = node.createAddNode(self.roundness_att, 0.00001)
pm.connectAttr(add_node + ".output", self.tws1_rot.attr("sx"))

pm.connectAttr(self.armpit_roll_att, self.tws0_rot + ".rotateX")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -308,9 +308,14 @@ def addObjects(self):
)

# tws_ref
t = transform.getRotationFromAxis(
datatypes.Vector(0, -1, 0), self.normal, "xz", self.negate
)
if self.up_axis == "y":
t = transform.getRotationFromAxis(
datatypes.Vector(0, -1, 0), self.normal, "xz", self.negate
)
else:
t = transform.getRotationFromAxis(
datatypes.Vector(0, 0, -1), self.normal, "xz", self.negate
)
t = transform.setMatrixPosition(t, self.guide.pos["ankle"])

# addind an npo parent transform to fix flip in Maya 2018.2
Expand Down Expand Up @@ -776,10 +781,10 @@ def addOperators(self):

applyop.oriCns(ori_ref, self.tws0_loc, maintainOffset=True)

self.tws0_loc.setAttr("sx", 0.001)
self.tws2_loc.setAttr("sx", 0.001)
self.tws0_loc.setAttr("sx", 0.000001)
self.tws2_loc.setAttr("sx", 0.000001)

add_node = node.createAddNode(self.roundness_att, 0.0)
add_node = node.createAddNode(self.roundness_att, 0.000001)
pm.connectAttr(add_node + ".output", self.tws1_rot.attr("sx"))

# Volume -------------------------------------------
Expand Down

0 comments on commit 09628b5

Please sign in to comment.