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

New Post: Check if filetype is supported

$
0
0
This library supports impressive number of file formats so I was wondering is there way to check if file is supported before opening.

For example in a thumbnail viewer application what is be best way to check before attempting to to open as image? Should I
  • just wrap it in try/catch,
  • should I list all (extension == "jpg" || extension=="png"... and unintentionally maybe miss a few
  • or is there something like bool b =isSupported("jpg")?

Viewing all articles
Browse latest Browse all 3693

Trending Articles



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