Hi Paul,

"Paul L. Bogen" <[EMAIL PROTECTED]> wrote on 07/16/2007 01:20:13 PM:

> >    One thing is that I'm not entirely sure you have a clear 
> > idea of what you actually want when someone passes in a 
> > rotation of 45Deg with a scale of 2x and a translate of 200,100. 
> 
> I want the scaled object to be rotated 45 degrees respective to the post
> scaled center of the object and the object's upper left corner
> translated to 200,100.

   I believe this will do what you want:

        AffineTransform at = 
AffineTransform.getScaleInstance(scaleX,scaleY);
        at.rotate(angle*(Math.PI/180), scaleX*w/2.0, scaleY*h/2.0);
        at.translate(x, y);


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to