SVG has white background instead of transparent

MagickWand for PHP is an object-oriented PHP interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning MagickWand for PHP.
Post Reply
Jedateach
Posts: 1
Joined: 2012-08-05T13:47:48-07:00
Authentication code: 67789

SVG has white background instead of transparent

Post by Jedateach »

I'm getting a white background whenever I convert svg to png using php magickwand. Is this a bug?

php magickwand version: 1.0.8
ImageMagick version: 6.7.8-3

Code: Select all

$wand = NewMagickWand();
$transparentColor = NewPixelWand();
MagickReadImage($wand,"RAID_5.svg");
PixelSetColor($transparentColor, 'transparent');
MagickSetBackgroundColor($wand, $transparentColor);

MagickSetImageFormat($wand,"PNG24");
header('Content-Type: image/png');
MagickEchoImageBlob($wand);
Related: http://stackoverflow.com/questions/4149 ... magickwand
Post Reply