Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
I have ImageMagick set up on my wiki to convert SVG files to PNG (for inline usage), and I am getting a very strange result. The round edges of the SVGs are not, well, being round. They are being very jagged.
(click for original SVG)
Here's the command line that is used (replace $width with width in px, $height with height in px, $input with the SVG, $output with the desired PNG:
The only issue is that your black has changed to a light purple. Note the input image placement and the {} to avoid the interpreter seeing $widthx and looking for such variable.
The only issue is that your black has changed to a light purple. Note the input image placement and the {} to avoid the interpreter seeing $widthx and looking for such variable.
I tried using those settings and got an error: "Error creating thumbnail: convert: negative or zero image size `/home/pidginet/public_html/wiki/images/3/3f/Stormfront_-_TCG_set_symbol.svg' @ error/resize.c/ResizeImage/2554."
EDIT: I just tested out the command line with nothing but input and output, and still got the jagged edges. There must be an error with the installation, or the XML rendering just sucks.
Last edited by immewnity on 2011-06-17T12:38:45-07:00, edited 1 time in total.
fmw42 wrote:You might try downloading and installing RSVG and then re-install the latest IM.
Try using my command line, but substitute the exact numbers rather than use variables and see what happens.
What platform are you on?
My host says that they won't install RSVG, and they don't allow root access.
I checked the command line, and just simply having input and output still shows the jagged edges. I have a feeling that it is a corrupted installation somewhere.
My guess is that it is SVG vs RSVG. The latter usually works better. This is what I get from my command using IM with RSVG:
It is also possible that your result is an issue with PNG output as the PNG coder has been improving the PNG function over quite some time now and there were errors at times. So try saving as tif for example and see if that is any better. For me, PNG and TIF results look similar.
fmw42 wrote:My guess is that it is SVG vs RSVG. The latter usually works better. This is what I get from my command using IM with RSVG:
It is also possible that your result is an issue with PNG output as the PNG coder has been improving the PNG function over quite some time now and there were errors at times. So try saving as tif for example and see if that is any better. For me, PNG and TIF results look similar.