Magick.NET
Magick.NET copied to clipboard
How to ignore unknow tiff Tag(32934 , etc) when use MagickImage open such tiff image ?
Magick.NET version
13.7
Environment (Operating system, version and so on)
Windows10, net framework 4.7.2
Description
MagickImage open a tiff file with Tag 32934 failed, i ues setting ignore it and open this tiff file successfully . settings.SetDefines(new TiffReadDefines { IgnoreTags = new[] {"32934" } });
I want to know how to ignore unknown tags in the future, so as to avoid errors when opening such tiff images with unknow Tag?
Steps to Reproduce
using (MagickImage magickimage = new MagickImage(picbytes, settings))
The way this option works is that it tells the tiff library to ignore the tags that you specified. There is no option to tell the library that it should ignore all unknown tags.
I want to avoid Magic.Net reporting an error when encountering an unknown Tiff Tag it should at least be able to open the image.
The problem is not that there are unknown tiff tags. The problem is that one of those tiff tags is invalid and contains data that cannot be read by the tiff library. Both a warning and error are being raised.
Would you like to add an optional options to ignore such warning and error when open tiff image ?
I hope to show the image even if it includes invalid tags.
That is out of my control. The library that is being used doesn't have an option to ignore these kind of errors.