[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-kimageshop
Subject:    Re: Rotate image dialog
From:       Michael Thaler <michael.thaler () ph ! tum ! de>
Date:       2005-03-28 15:30:42
Message-ID: 200503281730.42139.michael.thaler () physik ! tu-muenchen ! de
[Download RAW message or body]

On Monday 28 March 2005 17:21, Boudewijn Rempt wrote:
> On Monday 28 March 2005 17:15, Michael Thaler wrote:
> > On Monday 28 March 2005 16:47, Boudewijn Rempt wrote:
> > > * I want to give an old dimensions/new dimensions comparison. For that
> > > I need some way to access the dimensions of the layer/image after
> > > rotatating. The current rotate code doesn't give me that.
> >
> > x_new = QABS ( x_old * cos( phi ) ) + QABS( y_old * sin( phi) );
> > y_new = QABS ( y_old * cos( phi ) ) + QABS( x_old * sin( phi) );
>
> Thanks -- er, what is phi, actually?

phi is the angle by which the image is rotated. If the angle is in degrees, 
use cos( PI*phi/180 ) and sin( PI*phi/180 ) instead of just cos( phi ) and 
sin( phi ) in the above formulas. See the other mail:-)

Michael
_______________________________________________
kimageshop mailing list
kimageshop@kde.org
https://mail.kde.org/mailman/listinfo/kimageshop
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic