Dear All,
Sorry to bother this list for a simple question:
are there any MagickCore functions to detect what graphic format
(.gif, .jpg, etc.) for a given file?
Thanks.
--Wo
detect format type
Re: detect format type
I think I found the answer myself: just just image->magic.
--Wo
--Wo
Re: detect format type
If you just want to detect the format, use PingImage() instead of ReadImage(). PingImage() is lightweight.
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: detect format type
The 'magick' part is also available (completely outside of IM) using the "file" command. IM itself does similar things in determining image format styles.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/