ScriptSpot

Forum topic · General Scripting

Matrix3 rotation values >360

By artkitekt · 2012-01-28

Description

Dudes,

I am trying to create a matrix3 from a node's transform which has a rotation value that is more than 360 degrees (seen in the gimbal type-in). I need to use it for matrix math.

Problem : Accessing the node's transform matrix directly does not yield a value that reflects a rotation above 360 degrees. Wadaheo..

Check it out:

(
clearListener(); try(delete $myBox)catch()
myBox = Box length:50 width:50 height:50 name:"myBox"
myBox.rotation.controller[1].value = 720 -- Sets x rotation to 720
boxMatrix = myBox.transform
print (boxMatrix.rotation)
quatToEuler boxMatrix.rotation
)

Thanks for any help.

-Dru

Comments (2)

MKlejnowski · 2013-03-29

With matrix math you simply can't. Your gonna have to change your approach.