Original Post
🔒 Locked
Rotation
Advertisement
Do you mean that it''s sitting on the center of the world and rotating around the center or that it''s "orbitting" around the center? If you mean the latter, the order of your matrix multiplications is wrong.
In any case, you can add translations and rotate around any point you want, but the multiplication order matters.
There shouldn''t be any reason to break out the ol'' trig book...
In any case, you can add translations and rotate around any point you want, but the multiplication order matters.
There shouldn''t be any reason to break out the ol'' trig book...
Make sure you apply your rotation matrix before applying your translation matrix. That way the object will rotate about its own axis. Also, don''t forget to start with an identity matrix. I would do it like this:
(IdentityMatrix * RotationMatrix) * TranslationMatrix
I think that would work. If you think about the ordering as CrazedGenius said you should be able to achieve any sort of transformation.
(IdentityMatrix * RotationMatrix) * TranslationMatrix
I think that would work. If you think about the ordering as CrazedGenius said you should be able to achieve any sort of transformation.
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement