Re: Extracting The Scaling Component Of A Matrix

Behdad Esfahbod <[email protected]>
Newsgroups gmane.comp.lib.cairo
Message-ID <CAF63+7VBvx=CyB=4UVdsn96ciU-q7WmOYZN+fVg08_wReSi8Jw@mail.gmail.com>
On Dec 14, 2015 10:30 PM, "Arjen Nienhuis" <[email protected]> wrote:
>
> > Yeah... You have to define what exactly you want.  A 2D matrix like the
ones
> > cairo uses can always be decomposed into a concatenation of the
following
> > matrices:
> >
> >   - transform
>
> transform is what cairo calls translate right?

Err.  Yes, I meant translate.

> >   - rotate
> >   - skew
> >   - scale
> >
> > This has many useful properties, and you can derive those four
transformations
> > from an arbitrary matrix easily.  Here's my derivation:
> >
> >
https://readable-email.org/list/www-style/topic/better-matrix-decomposition-for-animation
> >
> > This also describes the benefits of such decompositions:
> >
> >
http://research.cs.wisc.edu/graphics/Courses/838-s2002/Papers/polar-decomp.pdf
> >
> > If you transform a circle with a matrix, you get an ellipse.  If you are
> > interested in the major and minor axes of that ellipse, that's a
Singular
> > Value Decomposition of the 2D matrix.  I've put code here for doing
that:
> >
> >
https://github.com/behdad/cairo/blob/color-emoji/doc/tutorial/src/singular.c
> >
> > Cheers,
> >
> > behdad
> > --
> > cairo mailing list
> > [email protected]
> > http://lists.cairographics.org/mailman/listinfo/cairo

-- 
cairo mailing list
[email protected]
http://lists.cairographics.org/mailman/listinfo/cairo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.