Page 1 of 1

2.40 api breaks bundled script

Posted: Sun Oct 16, 2005 7:13 pm
by xand
my bundled script 'axis rotation copy' doesn't work anymore with the 2.40 alpha.
there's a change in Mathutils with the definition of the size of the matrix in Matrix.toQuat()

the console log : "Traceback (most recent call last):
File "<string>", line 105, in ?
AttributeError: Matrix.toQuat(): inappropriate matrix size - expects 3x3 matrix"

but the strangest it's that i don't use .toQuat() in the script
the line affected is :

Code: Select all

so what happens to Mathutils and where can i find a good documentation to have working script ?

Posted: Sun Oct 16, 2005 8:43 pm
by stiv
The toQuat() error string also appears - somewhat incorrectly - in toEuler().

The code is checking for a 3x3 matrix.

Posted: Mon Oct 17, 2005 4:04 am
by ascotan
lol your right. will fix the error string.

You can only make 3x3 matrices into eulers.

Posted: Mon Oct 17, 2005 10:57 am
by xand
thanks, i add .rotationPart() before .toEuler() and it works.
but it will be cool to add a method to extract the real rotation part of the matrix without the scale.
so i cand avoid the use of .toEuler().toMatrix()


Posted: Mon Oct 17, 2005 12:14 pm
by ascotan
I'll see what I can do. :)