   quaternion rot between two vectors, but with an axis
  I saw another thread on how to find a quaternion between two vectors:http://www.gamedev.net/community/forums/topic.asp?topic_id=429507you do get the shortest rotation, but often the axis of the rotation (of the quaternion here..) is not necessarily the best for gameplay uses. I'd imagine in games, if this was for a camera related purpose, the best axis of rotation is that which is closest to the up vector (0, 1, 0).But how do you get such a quaternion? I was thinking of getting the average of the two vectors and the cross product to form a plane, and then project the up vector into this plane. Then, somehow using this new found vector, create the quaternion..But that's as far as I got, as it seems too messy. Is there a better way?   
  If you want to do a rotation around the y axis, just drop the y coordinates from the two vectors and use those to calculate the angle of rotation.   ;  Hmm.. that's true, but what if the game is a space sim and the up vector is not necessarily (0,1,0)? As it happens, I didn't think of doing that and it's probably a great hack for what I need (thanks).. but if there's a more general way of doing it, I'd implement it..   ;  It can be done with an arbitrary axis. If you've got an axis A and two vectors B and C, you'd take the projection of B on to A and subtract that from B to get D. And then take the projection of C on to A and subtract that from C to get E. Then you would use D and E to create your rotation. For A (0, 1, 0) the projection of B and C are just the y components of B and C, which leads to just dumping the components.   ;  Thanks, didn't think of that :D   