AWARE SYSTEMS
TIFF and LibTiff Mail List Archive

Thread

2004.01.15 17:16 "[Tiff] How to determine number of colors in the colormap", by Bill Cassanova
2004.01.15 18:44 "Re: [Tiff] How to determine number of colors in the colormap", by Joris
2004.01.15 18:59 "Re: [Tiff] How to determine number of colors in the colormap", by Bill Cassanova
2004.01.15 19:50 "Re: [Tiff] How to determine number of colors in the colormap", by Joris
2004.01.15 20:14 "Re: [Tiff] How to determine number of colors in the colormap", by Bill Cassanova
2004.01.15 21:32 "Re: [Tiff] How to determine number of colors in the colormap", by Joris

2004.01.15 19:50 "Re: [Tiff] How to determine number of colors in the colormap", by Joris

Thanks for writing.

No problem.

So to read the colormap am I doing it correctly? For some reason the results I am getting are

non-sensible. I would have expected to see values in the range of 0 to 255.

It's been a while since I build my interface to that stuff. I plan to return to it, that's the reason I'm here again, but when it comes to LibTiff, someone else's advice is no doubt better than my vague memory.

No, you should expect values like the ones you're seeing. The palette entries is 16bits per channel.

You could check your findings by comparing them with the output of my free TIFF Tag Viewer application for windows.

http://www.awaresystems.be/free_downloads/astifftools.html

If you want to convert them to the more familiar 8bit per channel range, see a very recent (and ongoing?) other thread on this subject tittled 'Colormap and byte padding'. No disrespect to other posters in that thread (especially no disrespect to myself, grin), but if you want a quick answer without browsing through the whole thread I should suggest that Marti Maria is the author of Little CMS and could be considered the authority on the matter.

Joris Van Damme
info@awaresystems.be
http://www.awaresystems.be