xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alan Deikman <Alan.Deik...@znyx.com>
Subject Re: JSVGCanvas Rotation with AffineTransform
Date Thu, 12 Mar 2009 02:37:14 GMT
Thomas Palfray wrote:
> Thanks for your answer.
>
> thomas.deweese@kodak.com a écrit :
>>
>> Hi Thomas,
>>
>> Thomas Palfray <thomas.palfray@gmail.com> wrote on 10/25/2008 
>> 05:08:39 AM:
>>
>> > Well, i'm working on an application wich need to rotate a JSVGCanvas
>> > (90°, 180°, 270°). I used AffineTransform and the method
>> > setRenderingTransform like that :
>>
>>    If you only need to support 90, 180 & 270 deg rotations.
>> I would suggest simply hard coding the correction factors.
>> For 90deg it will be a translate in X by the height before rotation.
>> for 180 deg it will be translate in X by the width and
>> in Y by the height (both before rotation), for 270 a
>> translate in Y by the width before rotation.
I'm having the same problem -- I have a JSVGCanvas I want to paint in 
different orientations.   I have tried the setRenderingTransform() 
method with no success -- it just gets overwritten by some other logic 
within batik with the identity transform when the component is resized.

Question: at what point can setRenderingTransform(at, true) be used or 
is meaningful within the lifecycle of GVT rendering process?

Another question -- is there anything to read to understand the usage of 
the different transforms in JSVGCanvas?   You have the initial 
transform, rendering transform, viewing transform, viewbox transform, 
and painting transform. 

Thanks in advance for any pointers.

-- 
Alan Deikman
ZNYX Networks


Mime
View raw message