Re: [eigen] get scaling out of transform?

[ Thread Index | Date Index | More Archives ]

This is currently unimplemented in Transform, and the computation
involved is really nontrivial.

It is definitely on my TODO for 2.1.

Here's an explanation. When you decompose a matrix as a product
rotation*scaling, that's called the "polar decomposition". Computing
the polar decomposition amounts to computing the SVD decomposition. In
Eigen 2.1 we'll have a very good SVD with fixed-size specializations
and I'll use that to implement scaling() and reimplement rotation()
correctly in Transform.

Meanwhile, if you don't care about performance, you can already use
the SVD in Eigen 2.0 but it's slow if only for lack of fixed-size

If the SVD of M is M = U D V^      (where ^ denotes adjoint, or
transpose for real matrices)
then you have M = U D U^  U V^
So your scaling is U D U^
and your rotation is U V^


2009/1/21 Ben Axelrod <baxelrod@xxxxxxxxxxxx>:
> Hi,
> How can I get the scaling info out of the Transform class?
> Thanks,
> -Ben

Mail converted by MHonArc 2.6.19+