diff options
author | Andrey Kiselev <dron@ak4719.spb.edu> | 2004-10-09 14:15:07 +0000 |
---|---|---|
committer | Andrey Kiselev <dron@ak4719.spb.edu> | 2004-10-09 14:15:07 +0000 |
commit | 4d968f4ac21d7763ffcc967a6a0d5958e5e30941 (patch) | |
tree | 0ac1ff55da0b0c1dd1767c724f385d961d652d71 | |
parent | 199de07e56dd537cff05c900c40db3e44776c72f (diff) | |
download | libtiff-git-4d968f4ac21d7763ffcc967a6a0d5958e5e30941.tar.gz |
Fixed TransferFunction tag handling reported by Ross A. Finlayson.
-rw-r--r-- | tools/tiff2pdf.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/tools/tiff2pdf.c b/tools/tiff2pdf.c index 04d1b93f..612274dd 100644 --- a/tools/tiff2pdf.c +++ b/tools/tiff2pdf.c @@ -1,9 +1,12 @@ -/* $Id: tiff2pdf.c,v 1.16 2004-09-10 11:50:57 dron Exp $ +/* $Id: tiff2pdf.c,v 1.17 2004-10-09 14:15:07 dron Exp $ * * tiff2pdf - converts a TIFF image to a PDF document * * $Log: tiff2pdf.c,v $ - * Revision 1.16 2004-09-10 11:50:57 dron + * Revision 1.17 2004-10-09 14:15:07 dron + * Fixed TransferFunction tag handling reported by Ross A. Finlayson. + * + * Revision 1.16 2004/09/10 11:50:57 dron * Fixed reading TransferFunction tag as per bug * http://bugzilla.remotesensing.org/show_bug.cgi?id=590 * @@ -1162,7 +1165,9 @@ void t2p_read_tiff_init(T2P* t2p, TIFF* input){ } if(t2p->pdf_minorversion < 2) t2p->pdf_minorversion = 2; - } + } else { + t2p->tiff_transferfunctioncount=0; + } if( TIFFGetField( input, TIFFTAG_ICCPROFILE, @@ -1745,7 +1750,11 @@ void t2p_read_tiff_data(T2P* t2p, TIFF* input){ if(t2p->tiff_transferfunction[1] != t2p->tiff_transferfunction[0]) { t2p->tiff_transferfunctioncount=3; + } else { + t2p->tiff_transferfunctioncount=1; } + } else { + t2p->tiff_transferfunctioncount=0; } if(TIFFGetField(input, TIFFTAG_WHITEPOINT, &xfloatp)!=0){ t2p->tiff_whitechromaticities[0]=xfloatp[0]; |