[Bf-python] More on Armature orientation problems

Ken Hughes khughes at pacific.edu
Thu Jun 9 04:34:40 CEST 2005


Kenney Phillis Jr wrote:
> i'd agree with this analysys, but i have been testing the same thing 
> over and over, and the bug isn't just that....
> it has a few other bugs that i keep havin to contend with.
> 1:  the armature and bones when you create it have a rotation to start off with.

I'm not sure what you're referring to by "a rotation"; the only thing
I noticed what that the object for each armature and bone I made had an X
rotation of 90 degrees.  Then i noticed that was because I was creating
them in the front view; creating in the top view made all object angles=0.

> 2: bones don't return there orientation information properly after they 
> are just created.

Which orientation?  The loc, head and tail all seem to agree with the
values shown for each bone using NKEY (Transforms Properties window).
The same for the quaternions; the initial values are all [x,y,z,w] =
[0,0,0,1], but once I edit the pose the value returned matches the Trans
Prop window.

The values returned by getRestMatrix() defintely seemed to be wrong, but
the other values for each bone seem (to me) to be correct; they all
seem to be in "bone space".

And as Gilbert pointed out, the rolls are all messed up; sometimes they
are valid and sometimes they're not.  In all the tests I have right now,
they have non-zero values and do not reflect what's set in the Trans
Pos window; they do seem to be propagated from parent to child somehow:
  * If Bone1's roll=45 and Bone2's roll=0, then Bone2.getRoll() returns 45
  * If Bone1's roll=45 and Bone2's roll=45, then Bone2.getRoll() returns 0
  * If Bone1's roll=45 and Bone2's roll=-45, then Bone2.getRoll() returns 90

Ken



More information about the Bf-python mailing list