View Full Version : aimConstraint mathematics?
yznah 10242007, 04:22 PM does anyone know the mathematics of the aim constraint?
i need to compute an euler angle with given vectors. i played with the angleBetween command with success but not perfect results
any ideas?


BenBarker
10242007, 09:19 PM
There's some C code here:
http://www.euclideanspace.com/maths/geometry/rotations/conversions/matrixToEuler/
as well as a description here that is pretty good:
http://home.comcast.net/~greg_slabaugh/publications/euler.pdf
For python examples, you can look inside the mat3 or mat4 classes of the cgkit:
http://cgkit.sourceforge.net/index.html
I find it is a great resource for matrix/vector math guidance, although not entirely straightforward since it is part of a much larger system.
Then there's the hacky way...
Load your vectors into an aim constraint, or load the decomposeMatrix plugin and put them into that, then read the results and delete the node. :)
yznah
10252007, 09:05 AM
oh thx for all these docs :) i'll keep that somewhere in a corner. looks interesting!
finally i used a aimConstraint node as you said, i don't delete it but it is heavily solicited with some particle expressions :p
CGTalk Moderation
10252007, 09:05 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©20002014, Jelsoft Enterprises Ltd.