convert svg to png

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?".
Post Reply
vladimircape
Posts: 7
Joined: 2014-07-09T06:15:04-07:00
Authentication code: 6789

convert svg to png

Post by vladimircape »

Hi, i install to my server ImageMagick 6.8.9-5 Q16 2014-07-09
try to convert svg to png and get errors
convert: unable to open image `/tmp/magick-27998tM19O5QnDkAn': No such file or directory @ error/blob.c/OpenBlob/2658.
convert: unable to open file `/tmp/magick-27998tM19O5QnDkAn': No such file or directory @ error/constitute.c/ReadImage/540.
convert: no images defined `4.png' @ error/convert.c/ConvertImageCommand/3187.
I use CentOS 6.4
Also i check lib for SVG

Code: Select all

 convert -list format | grep SVG 
and get

Code: Select all

 MSVG  -w+   ImageMagick's own SVG internal renderer
      SVG  -w+   Scalable Vector Graphics
     SVGZ  -w+   Compressed Scalable Vector Graphics
sample of file
https://yadi.sk/d/bbSYUTpAWGrZy
vladimircape
Posts: 7
Joined: 2014-07-09T06:15:04-07:00
Authentication code: 6789

Re: convert svg to png

Post by vladimircape »

tried other file get other error
[root@li323-56 root]# convert example.svg 4.png

(rsvg-convert:28717): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
The overwriting error message was: Operation not supported
Error reading SVG:Failed to open file '/tmp/magick-28716LvtlyGhvWN7d': No such file or directory

convert: unable to open image `example.svg': No such file or directory @ error/blob.c/OpenBlob/2658.
convert: delegate failed `"rsvg-convert" -o "%o" "%i"' @ error/delegate.c/InvokeDelegate/1153.
convert: unable to open image `/tmp/magick-28716Dej5TkNolKQl': No such file or directory @ error/blob.c/OpenBlob/2658.
convert: unable to open file `/tmp/magick-28716Dej5TkNolKQl': No such file or directory @ error/constitute.c/ReadImage/540.
convert: no images defined `4.png' @ error/convert.c/ConvertImageCommand/3187.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: convert svg to png

Post by snibgo »

It sounds like a major problem with the build. Do any conversions work? Eg:

Code: Select all

convert logo: x.png
convert logo: x.jpg
etc.

Perhaps you didn't install delegates before building IM.
snibgo's IM pages: im.snibgo.com
vladimircape
Posts: 7
Joined: 2014-07-09T06:15:04-07:00
Authentication code: 6789

Re: convert svg to png

Post by vladimircape »

snibgo wrote:It sounds like a major problem with the build. Do any conversions work? Eg:

Code: Select all

convert logo: x.png
convert logo: x.jpg
etc.

Perhaps you didn't install delegates before building IM.
i tried
convert obratnai.jpg 5.png
and everything is correct
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: convert svg to png

Post by snibgo »

Your mono-ex-fix-clamp.svg converts for me without complaint. I suspect your IM isn't built or installed correctly.

You might try with Inkscape in your path, so IM will use that instead of its internal renderer.

You might try rebuilding IM, from scratch, starting with SVG components.

Beyond that, I have no suggestions. Sorry.
snibgo's IM pages: im.snibgo.com
Post Reply