Jump to content
  • Advertisement
Sign in to follow this  
chipmunk1886

transforming between two coordinate axis

This topic is 4733 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

okay, i'm making an oriented bounding box tree class that will eventually be incorporated into an object class (as in, every object will have a bounding box hierarchy). I'm confused about some of the math though. Each bounding box node will have matrix describing how to transform from the parent box: parent box coordinate system * some transformation matrix = child box's coordinate system (I hope i explained that correctly). I'm stuck on the construction of the transformation matrix given the two coordinate systems. The best i can come up with is calculate the angles between each of the axis and construct a transformation matrix based on euler angles but it seems like there should be an easier way. The reason i'm doing it this way and not storing a static coordinate system is that if the model is translated or deformed or whatever then the bounding box heirarchy will won't have to be modified (like skeletal animation i guess). Any help is greatly appreciated. Thank yee.

Share this post


Link to post
Share on other sites
Advertisement
The axises of a coordinate system are really just a basis for a vector space. When you want to convert from one basis to another basis (of the same vector space) what you need is commenly known as a change of basis matrix. Google should help you from there it would be a fair amount to type out here.

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!