3D rotation based on 2 vectors...
couldn't you just use gluLookAt to generate the matrix using the two vectors, then apply that matrix to your object? Best way I can think of.
Quote:Original post by anist
couldn't you just use gluLookAt to generate the matrix using the two vectors, then apply that matrix to your object? Best way I can think of.
doesnt gluLookAt just change the camera? This is what i'm pretty much trying to do (use gluLookAt for an object) so how do i get the matrix from it?
That's what I gave in my post. gluLookAt will modify the matrix stack itself. To accomplish what gluLookAt does, use the steps in my post to calculate the matrix.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement