AWARE [SYSTEMS] Imaging expertise for the Delphi developer
AWare Systems, Imaging expertise for the Delphi developer, Home TIFF and LibTiff Mailing List Archive

LibTiff Mailing List

TIFF and LibTiff Mailing List Archive
May 2007

Previous Thread
Next Thread

Previous by Thread
Next by Thread

Previous by Date
Next by Date

Contact

The TIFF Mailing List Homepage
This list is run by Frank Warmerdam
Archive maintained by AWare Systems



Valid HTML 4.01!



Thread

2007.05.04 11:51 "TIFFSetField and float values", by <mikk@go2.pl>
2007.05.04 12:18 "Re: TIFFSetField and float values", by Andrey Kiselev
2007.05.04 12:46 "Re: TIFFSetField and float values", by <mikk@go2.pl>
2007.05.04 13:02 "Re: TIFFSetField and float values", by Joris Van Damme
2007.05.04 13:13 "Re: TIFFSetField and float values", by Toby Thain
2007.05.04 13:20 "Re: TIFFSetField and float values", by Joris Van Damme
2007.05.04 21:06 "TIFFSetField and float values", by Mahmoudi Wafa

2007.05.04 12:18 "Re: TIFFSetField and float values", by Andrey Kiselev

On Fri, May 04, 2007 at 01:51:02PM +0200, mikk wrote:
> I'm fighting with saving TIFFTAG_XRESOLUTION and TIFFTAG_YRESOLUTION
> into a TIFF file.
> 
> AFAIK TIFFSetField is supposed to have 32 bit float as 3rd parameter
> and I pass such type of parameter to TIFFSetField. The tag value is
> saved (the tag is added to the IFD), but always has value of 0.0
> instead of passed parameter.

How do you checking result? The common mistake here is to read
Resolution value into integer variable, but it should be float one, i.e.

float xres;
TIFFGetField(tif, TIFFTAG_XRESOLUTION, &xres);

Best regards,
Andrey

-- 
Andrey V. Kiselev
ICQ# 26871517