2017.01.05 20:14 "Re: [Tiff] photometric value different when get from TIFF tag or from a TIFFRGBAImage", by Vincent Torri
On Thu, Jan 5, 2017 at 8:55 PM, Olivier Paquet <email@example.com> wrote:
2017-01-05 14:30 GMT-05:00 Vincent Torri <firstname.lastname@example.org>:
I have attached a small test program which displays the photometric
value of an attached TIFF file
from TIFFRGBAImage: value is 2
from TIFF tag, value is 32845
from TIFFPrintDirectory() (which uses TIFF flag ?) it is also 32845
Is it normal or is it a bug?
I think it is normal. Your file is LogLuv but the RGBA API converts it to RGB for you. The man page of TIFFRGBAImageBegin mentions that.
ha, ok, it seems normal, indeed
>> which value should I choose in case there is no bug?
It depends what you need the value for. To interpret the data you get from the RGBA API, 2 (RGB) should be the correct value.
I am writing a multi-document viewer and i'm writing a plugin for TIFF files with multiple directories. I want to display the informations of the TIFF file (and directories too).
So I will use the tags