2005.03.03 17:19 "[Tiff] LibTIFF question", by Kalman Miklos

2005.03.03 18:28 "Re: [Tiff] LibTIFF question", by Frank Warmerdam

No it is not documented. That's my problem. I just want to read the information stored in the tag. I know the tag ID and just want a simple char* buffer that I can read. There must be an easy way to do this in LibTiff isn't there?


Traditionally libtiff required library updates, or fairly complex extension mechanisms to register application specific tags. So the answer to "there must be an easy way of doing this" certainly was "no" till recently. The support for runtime defined tags is relatively new, and poorly documented. Also somewhat buggy no doubt.

BTW, you don't seem to have mentioned what version of libtiff you are using.

If I use int* data wouldn't that make it a 4 byte array? I tried with char buf[200], but all I got was 3 bytes which is not correct, since the data should contain 121 bytes. Maybe even a read raw function would be good.

I think I leaped to the conclusion your tag data was in from your use of the iVal variable in your first message. You can also use:

 char *data;

If the call isn't working, you should (as suggested) make available at least a tiffdump report for your file, and ideally a sample file itself so that we can try to reproduce your problem.

Best regards,

I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam@pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent