The objects “new” x-axis is IN your rotation matrix. Remember that a matrix is the 3 unit vectors that make up the transformed coord system.
Start with the identity matrix,
Get the 3 values out of the matrix that are the objects x-axis (either m, m, m or m, m, m - can’t remember).
translatef by that vector and you’re done.
Hope that helps, i’m not too good at explaining fings.
Originally posted by Bob:
And who says it’s forbidden to rotate after translation? What if I want that effect, will OpenGL stop me from doing that?
Of course not (as you know very well) !
I was just assuming that he wanted the rotation to spin the object, without changing its position. As you know, it is very common, and I was assuming that he was a beginner, so he would do only very common things…