'.CDR to .SVG Convert Using ImageMagick

I am on CentOS 6.4 and trying to convert .CDR to .SVG Convert Using ImageMagick using SSH command.

  1. my 1.cdr file is in /var/www/vhosts/website.com/httpdocs/test/1.cdr
  2. once converted to SVG it should be created in the same folder

Tried the following command:

convert /var/www/vhosts/website.com/httpdocs/test/1.cdr image.svg

The Error I am getting is:

sh: mplayer: command not found convert: Delegate failed "mplayer" "%i" -really-quiet -ao null -vo png:z=3' @ delegate.c/InvokeDelegate/1032. convert: missing an image filename image.svg' @ convert.c/ConvertImageCommand/2800.

Not sure what does that mean ?



Solution 1:[1]

In order to convert CDR files you need to install uniconvertor for CDR delegate.

List of all delegates:

convert -list delegate

By default it outputs:

cdr =>          "uniconvertor" "%i" "%o.svg"; mv "%o.svg" "%o"

Install uniconvertor. For example, on Ubuntu it’s:

sudo apt-get install python-uniconvertor

Then run:

convert image.cdr -flatten -thumbnail '512x512' image.png

Or, with zoom cropping:

convert image.cdr -flatten -thumbnail '512x512^' -gravity center -crop 512x512+0+0 +repage image.png

And you’re done.

I convert to PNG here but you may use your own output format.

Solution 2:[2]

python-uniconvertor is part of inkscape.

It does not exist by itself.

Ubuntu/Mint recently removed all the old Python stuff, for Corel Draw I have to fire up the WinXP VM & Corel and export something Linux understands, usually PNG, a favourite

CDR & WMF files are pretty much dead to Linux, ImageMagick can still handle WMF though.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1
Solution 2 Tyler2P