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
December 1996

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!



1996.12.16 12:25 "no more strip chopping as default !", by Louis Garde

( * VERSION: v3.4beta035 )
( * TARGET: sparc-sun-solaris2.5 )

  I think it would be better to have no strip chopping as default behaviour,
because it may induce unexpected behaviour in all applications that uses the
standard "r" option to open a Tiff file - this is what happened to me after
updating an old version of libtiff without strip chopping.

  It is clearly specified in the TIFFOpen man page that :

"Strip chopping does however alter the apparent contents of the
 image because when an image is divided into multiple strips it
 looks as though the underlying file contains multiple separate
 strips [tiles]."

  The trouble is that strip chopping is the default mode of the libtiff
package :
tiffconf.h, line 122
        #define STRIPCHOP_SUPPORT  1  /* enable strip chopping */

tif_open.c, line 164 :
	/*
	 * Default is to return data MSB2LSB and enable the
	 * use of memory-mapped files and strip chopping when
	 * a file is opened read-only.
	 */
	tif->tif_flags = FILLORDER_MSB2LSB;
	if (m == O_RDONLY)
		tif->tif_flags |= TIFF_MAPPED|TIFF_STRIPCHOP;

  I have noticed that the tiffinfo tool currently returns erroneous
information for some uncompressed stripped files, because it does not use the
"rc" option when opening the file. So if the strip chopping remains the
default, then the opening mode of tiffinfo (and may be other tools) should be
updated.

Louis.