This project is read-only.

Save as PNG with Transparent Background

Dec 8, 2011 at 11:37 PM
Edited Dec 9, 2011 at 5:39 AM
I can scale and convert from svg to png fine.  But it saves the image with a white background.  Any ideas how to make this transparent when saving?
var svg = SvgDocument.Open(inputImage);            

var maxSide = Math.Max(svg.Width, svg.Height);
var scale = (float)_maxSize / maxSide;

svg.Width = new SvgUnit(svg.Width.Type, svg.Width * scale);
svg.Height = new SvgUnit(svg.Height.Type, svg.Height * scale);

[update] disregard, i had another filter that was clearing the background as white after going through this filter.