Quantcast
Channel: magick Discussions Rss Feed
Viewing all articles
Browse latest Browse all 3693

New Post: Converting from AI/SVG to PNG with transparent backgrounds.

$
0
0
Ok, so I have been playing around with this and here are a few things I have noticed.

If I used:
image.Settings.BackgroundColor = new MagickColor(System.Drawing.Color.Red);
then the background is infact red and I can actually see the rest of my image (i.e. the logo)

if I try:
image.Settings.BackgroundColor = MagickColors.Transparent;
then everything is transparent and I can't see anything. I have checked the dimensions of the image and they are 500px wide and about the same height so it isn't that it's too small to see.
So, I thought I would do a combination of the 2 to see what happens.
So I tried:
image.Settings.BackgroundColor = new MagickColor("#7FFF0000"); // Red at 50% transparency
I would expect to see a transparent red background at 50% transparency, but instead I still get an entirely transparent image :(

All this has been happening with this SVG file: http://portalvhdswfr5fqfcn6r95.blob.core.windows.net/kudos-sports/67c49467-c9ed-4662-a4a6-08ed2c3536ce.svg
If I try with the AI file I just get a white background :(
Surely this has happened to others?

Viewing all articles
Browse latest Browse all 3693

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>