What's the best/fastest way to get the count of tiff tags from a tif image with LibTiff.Net?

StackOverflow https://stackoverflow.com/questions/12223041

  •  29-06-2021
  •  | 
  •  

Domanda

Just as stated in the title, what is the best and fastest way to get the count of tiff tags in an image?

Currently the only way I know of is trying to query tags 1-65534 using the GetField() method and simply counting that way. Is there some type of array or list of tags that I can access from the Tiff object in the LibTiff.Net library?

È stato utile?

Soluzione

Your current approach is the only one available through API. So, obviously, it's the fastest one.

Tiff class maintains internal representation of current image directory (page). This information contains all found tags. But probably it's not worth the hassle to try to get to that information.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top