Hi Gerrit,

> When I display a bounding box for a rotated circle (which should have
> the same bounds no matter how it is rotated) the box changes as if the
> original square bounding box was part of the shape, e.g. the bounds get
> larger as you approach 45 degrees. That would mean that the bbox is in
> fact a maximum bbox. The exact bounds can't be larger (so it's safe to
> clip), but they could be smaller.

Wow, I'd say this is pretty weird. Please provide some background
information, such as Batik version (or revision if using the source
code [1]), Java version, operating system etc.. Also, are you able to
create a reduced test case [2]?

Note that I haven't (yet) tried to reproduce the issue. Naturally,
this may even be expected -- also I haven't (yet) double check the
specification regarding this, though intuitively it would seem
awkward. Currently, I'm just inviting you to share a bit more so one
to be able to take a better look at this.


> Is there another method that would yield the accurate bounds of
> transformed shapes? My idea would be as follows:
[...]
> Does something like this exist already? Or am I maybe missing something
> important here?

Seems like "getTransformToElement" [3] might help you. There's a great
sample, "How to get the boundingbox of an svg element" [4], which
proofs the concept.


> Many thanks and best regards,
> Gerrit

Hope this helps,
 Helder


[1] http://xmlgraphics.apache.org/batik/download.html#Subversion+repository
[2] http://webkit.org/quality/reduction.html
[3] http://www.w3.org/TR/SVG11/ecmascript-binding.html
[4] 
http://my.opera.com/MacDev_ed/blog/2009/01/21/getting-boundingbox-of-svg-elements

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to