Hi Carsten,

Am 15.08.2014 16:51 schrieb Carsten Neumann <carsten.p.neum...@gmail.com>:
>
> Hello Michael, 
>
> On 2014-08-15 14:09, Michael Raab wrote: 
> > If I try to decompose 2 Matrices which are nearly the same I get a 
> > result scale vector that has switch axis. Here's an example: 
> > Matrix 1: 
> >     1.040   -1.040    0.000    0.000 
> >     0.707    0.707    0.000    0.000 
> >     0.000    0.000    1.000    0.000 
> >     0.000    0.000    0.000    1.000 
> > Result 1: 
> >    Rotation 0, 0, 45 
> >    Scale 1.47031, 1, 1 
> >    Scale Orientation 0, 0, -0.382683, 0.92388 
> > Matrix 2: 
> >     1.046   -1.046    0.000    0.000 
> >     0.707    0.707    0.000    0.000 
> >     0.000    0.000    1.000    0.000 
> >     0.000    0.000    0.000    1.000 
> > Result 2: 
> >    Rotation: 0, 0, 45 
> >    Scale: 1, 1.47986, 1 
> >    Scale Orientation: 0, 0, 0.382683, 0.92388 
> > Has someone an explanation for this? 
>
> assuming that recombining this back into matrices yields the starting 
> matrices (i.e. it is not a bug in the decomposition) this would be 
> caused by a degree of freedom in the algorithm.

Does it really  produce the initial Matrix? Haven't tested this...

> I can think of the following options: 
> - figure out where this degree of freedom is and make choose the scale 
> orientation more consistently.

Sorry I don't understand this..

> - can you use a ComponentTransform instead of a plain Transform and only 
> modify the individual components. That would make the decomposed form 
> the canonical representation and only build the matrix from those.

That is not an option as the matrix is the result of a sequence of 
transformations.

> - can you make assumptions about the matrix, e.g. is it composed from 
> translation, rotation, and (uniform) scale only?

Unfortunately not. The only assumption I can think of is that the scale should 
be applied without any additional scale orientation.
Usually I think of transformation matrices as a combination of the 3 components 
translation, rotation and scale. Actually I do not know where the scale 
orientation is necessary or useful.

Michael

>
> Cheers, 
> Carsten 
>
> ------------------------------------------------------------------------------
>  
> _______________________________________________ 
> Opensg-users mailing list 
> Opensg-users@lists.sourceforge.net 
> https://lists.sourceforge.net/lists/listinfo/opensg-users 
------------------------------------------------------------------------------
_______________________________________________
Opensg-users mailing list
Opensg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to