I have 2 matrices. Matrix A and Matrix B which is a 'matrix A rotated by some angle around some axis' (quaternion?). So: B = A.Transform (quaternion).
now when I know B and A, and maybe axis, how do I find the angle of that quaternion?
Sorry for bad text, I'm on a German keyboard and I'm not German...
So you have B = A x T
therefore A-1 x B = T
So take the matrix inverse of A and multiply that by B to get the Transform matrix.
Then extract the quaternion, (or Euler angles, if you would prefer), using say http://www.cg.info.hiroshima-cu.ac.jp/~miyazaki/knowledge/teche52.html