Page 1 of 1
Bug XY Coordinates
Posted: 2012-05-23T03:24:43-07:00
by Morgano
Hello,
i try to convert this SVG:
http://www.getshirts.de/upload/test_svg.svg
into:
The Result after conversion is
The X and Y Value of the Inline SVG : <svg id="svg_motiv1" x="136" y="122" width="125" height="40" viewBox="0 0 16.3877 5.27807" > is set to zero
The width + height is ok.
Any suggestions - is there a workaround?
Greets Morgano
Re: Bug XY Coordinates
Posted: 2012-05-23T23:39:44-07:00
by anthony
Check what SVG delegate method is being used!
http://www.imagemagick.org/Usage/draw/#svg
Re: Bug XY Coordinates
Posted: 2012-05-24T10:39:35-07:00
by fmw42
I got even worse looking results using RSVG (no shirt showing at all).
Re: Bug XY Coordinates
Posted: 2012-05-25T00:32:30-07:00
by Morgano
Is here a global problem because the 2 svgs?
Code: Select all
<svg id="main_svg" width="400" height="400">
<svg id="svg_motiv1" x="136" y="96" width="128" height="32" viewBox="0 0 57.0653 14.1677" >
</svg>
</svg>
Greetings Morgano
Re: Bug XY Coordinates
Posted: 2012-05-27T16:03:18-07:00
by anthony
I ran your test svg file with "rsvg_view" (direct use of the RSVG library withotu Imagemagick) and it only showed the shirt.
No "Thinking..." bar at all. -- though it was a little slow (vectored images will do that! SVG is not designed for raster images)
I get the same result with ImageMagick. Not surprising really.
Re: Bug XY Coordinates
Posted: 2012-05-28T08:19:38-07:00
by Morgano
Hello Anthony,
thanks for testing.
I did not have the problem with image and vector.
When you read the sourcecode of the svg - you see everything is in there. You see it correct in browser?
But i recognize that Imagemagick has a problem with two svgs nested / encapsulated.
Is this final that nested svgs cannot be rasterized?
We want to use imagemagick instead of Batik for Tomcat Server.
Thanks and greets Morgano
Re: Bug XY Coordinates - Update
Posted: 2012-05-29T07:20:12-07:00
by Morgano
Hello,
here a new and simplified description of the Bug without images:
This should be the result
Instead the SVG rasterize this:
The SVG:
http://www.getshirts.de/upload/im_test2_c.svg
The Problem is the same:
the x and y coordinates of the incapsulated svg is wrong and set to zero
Encapsulated SVG should raster correct:
http://svg.tutorial.aptico.de/start3.ph ... -Elementen
The Code:
Code: Select all
<?xml version="1.0" encoding="ISO-8859-1" standalone="no" ?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg width="200" height="200" xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink">
<rect x="0" y="0" width="200" height="200" style="fill:red;" />
<svg x="10" y="10" width="100" height="100">
<rect x="0" y="0" width="100" height="100" style="fill:blue;" />
</svg>
</svg>
will not raster correct.
Have i explained the problem understandable?
Thanks for your help
Greetings from germany Morgano
Re: Bug XY Coordinates
Posted: 2012-05-29T09:20:23-07:00
by fmw42
With your im_test2_c.svg, on IM 6.7.7.3 Q16 Mac OSX Snow Leopard,
This works fine using RSVG:
convert im_test2_c.svg im_test2_c.png
This fails as you show using IM internal MSVG
convert MSVG:im_test2_c.svg im_test2_c2.png
I recommend you install RSVG and then you have the choice to use either, which ever works best.