What can I do to identify and separate matrix-data?

i have a matrix with 16 values.
I can use the “ApplyTransform”-Node to Identify
XYZ out of the Values. Is there anybody in the
Knowledge of an easy way to separate the other Values like Rotation(Angle), pitch, roll, yaw , etc.

if there is scaling and rotation involved, there is no solution see this post

ok. I know a little bit more now.

I’m dealing with a OpenGL-Matrix in VVVV.

It is a Translation- and Rotation-Matrix looking like this:

n n n 0
n n n 0
n n n 0
x y z 1

I don’t know how to go on to get useful Rotation-Data.
I hope I have not read over some information in the other post.

if you just want to use the openGL matrix, use SetMatrix (transform) to create a transform out of it.

i know. i did this.

so what i want to do with this:

i have some objects.
from each object i get a matrix.
i want to interconnect and compare
these objects and their rotation
(and position) data to perhaps
control totally different data.

i thought for this task it would be better
to have clean rotation data seperated
from the position and not in the matrix.

perhaps i’m thinking too complicated?

hm, you could try the ApplyTransform (Direction) and put the output vector into a Polar node to get the angles…

the book Graphics Gems II has an article “Decomposing a matrix into simple transformations” on page 320 (i did not find the full text on the net, just a c++ implementation of that code) it proposes to be able to decompose a non-degenerate 4x4 transformation matrix into the sequence of transformations that produced it.

so as i understood:
there is no smart way in vvvv
to decompose viewmodel-matrices.
it is better to do this before.

not now, but there might be some day.
i didnt went to the c++ close enough to decide if it can be implemented with the current vvvv feature set as a module. it may well be, though…

there is the possibility to get the roation matrix as a quaternion before going to vvvv.

do you think this would be better to separate and work with the data?

especially the slerp and axisangle nodes seems to be interesting.
but i never worked with quaternions so i cannot decide
if it is worth in my case to go the quaternion way.


quaternions are cool. think of it as an angle and and an axis, specified by xyz for the axis, and w for the rotation. the great thing is that you can linearly interpolate these four numbers and still get nice paths inbetween. you wont get these paths when interpolating yaw, pitch and roll angles. apart from that its just another way to specify rotations.

see e.g. Quaternions and spatial rotation and Gimbal Lock