Jump to content
  • Advertisement
Sign in to follow this  
Bulma

Scale orientation from Transformation Matrix

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

I am writting VRML like exporter for 3dsmax. Transformation in VRML is defined as: P' = T × C × R × SR × S × -SR × -C × P where: C-center SR-scaleOrientation S-scale T-translation R-rotation There is no problem in extracting Translation and Rotation, but how do i get scaleOrientation? Thanks

Share this post


Link to post
Share on other sites
Advertisement
I would assume the scale orientation is a rotation and the scaling is strictly along the axes, i.e. x, y, z and perhaps w scaling.

Share this post


Link to post
Share on other sites
You have two options:

1.) Use the 3D Studio Max decomp_affine(...) function to decompose the matrix into the elements you need. This includes the scale orientation, which is stored in the affineParts.u member if I remember correctly from the top of my head.

2.) Use Ken Schoemake's code from Graphics Gems which basically does the same thing as the decomp_affine, which uses polar decomposition of the matrix.


I used both, but ended up having to use the 3DSMax native decomp_affine later on as I had some issues with animating / interpolating the scale orientation when using the results of Ken's code.

So just check out the decomp_affine function in Max. It will give you exactly what you need :)

- John

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!