Hi magick developers team
I convert svg file to png
That's ok to convert but when I see png, it is very bad quality of text element! How to set magick setting to view nice qulaity of png file?
try
{
ImageMagick.MagickImage image = new ImageMagick.MagickImage(@"c:\1.svg");
image.Format = ImageMagick.MagickFormat.Png;
ImageMagick.Density de = new ImageMagick.Density(400, 400);
image.Density = de;
ImageMagick.Percentage pe = new ImageMagick.Percentage(25);
image.Resize(pe);
image.Settings.TextAntiAlias = true;
ImageMagick.MagickColor mc = new ImageMagick.MagickColor(Color.Transparent);
image.Transparent(mc);
ImageMagick.QuantizeSettings a = new ImageMagick.QuantizeSettings();
a.DitherMethod = ImageMagick.DitherMethod.Riemersma;
image.Write(@"c:\Magick.png");
}
catch (Exception ex)
{
}
I think text anti alias on magick is sharp but I need smoothed or crisp like svg library
I don't need to change size of image.
default resolution on my project is 72 and my size is fixed.
can you help me?
why are you dithering? seems to me that would make the edges more aliased
have you tried the command given by Magick for supersampling in the command line?
Imagemagick uses delegates to convert svg to raster such as png. The best delegates are Inkscape first and then RSVG and then IM internal MSVG (XML). Which are you using?
dixita wrote: ↑2017-03-09T00:39:53-07:00
Hey i just convert my gravtar in svg to png. but i cant go back.. any solution??
Sorry, I do not understand the question! What is "gravtar"?
Once you convert svg to png and delete the svg, you cannot go back. Imagemagick is a raster processor. It does not vectorize! So you cannot effectively do png to svg. See http://www.imagemagick.org/Usage/formats/#vector
But I don't need resize my image with high resolution.
fmw42 wrote: ↑2017-03-09T00:28:35-07:00
Imagemagick uses delegates to convert svg to raster such as png. The best delegates are Inkscape first and then RSVG and then IM internal MSVG (XML). Which are you using?
Furthermore I need c# .net to convert svg to png
I make svg string at runtime and convert it on the fly to png
I think command line is bad solution to convert svg string to memory stream image
What's your solution?