• Advertisement
Sign in to follow this  

Rotation question

This topic is 4887 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

If I want to make an object rotate its self, such as box. I don't want the object rotate parrelle with Y axis, X axis or Z axis. I want it rotate parrelle with custom axis, such as (5,6,7)----(10,12,14) axis.It is possible to rotate like this ?

Share this post


Link to post
Share on other sites
Advertisement
The conceptually easy way to do it is:

Step one: rotate the object so that an axis (for example the Y axis) aligns with your new axis.
Step two: perform the rotation about the newly aligned axis (y in this case).
Step three: Undo step one by rotating by the inverse of the matrix in step 1.

You can concatenate this to one matrix; just remember the transforms are applied right to left, so its M3*M2*M1.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement