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

New Post: Detect best save format PNG or JPG

$
0
0
You can always get the type of the image with the Format property of a MagickImage. But you cannot detect if an SVG file has an embedded image without parsing the xml of that file and Magick.NET cannot do that for you. I think using the total number of colors to detect clip art is a good idea, you could use the TotalColors property for that. If you want to get more detailed color information you could use the Histogram method. You might also want to use HasAlpha to check if the image has an alpha channel and then save a PNG because JPG does not support transparency.

Viewing all articles
Browse latest Browse all 3693

Trending Articles



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