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
August 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.08.03 17:30 "bug? copying tiled tiffs over 2GB seems to break", by <jcupitt@gmail.com>
2007.08.03 18:07 "Re: bug? copying tiled tiffs over 2GB seems to break", by <jcupitt@gmail.com>
2007.08.03 18:10 "Re: bug? copying tiled tiffs over 2GB seems to break", by <jcupitt@gmail.com>
2007.08.03 19:12 "Re: bug? copying tiled tiffs over 2GB seems to break", by Frank Warmerdam
2007.08.06 11:31 "Re: bug? copying tiled tiffs over 2GB seems to break", by <jcupitt@gmail.com>

2007.08.03 19:12 "Re: bug? copying tiled tiffs over 2GB seems to break", by Frank Warmerdam

jcupitt@gmail.com wrote:
> Hi,
> 
> I have a problem with a pyramid builder I wrote. It seems to break for
> pyramids larger than 2GB with tiff 3.8.2. I think (I hope this is
> right) it's supposed to work for files up to 4GB.
> 
> Here's a small test program:
> 
>   http://www.vips.ecs.soton.ac.uk/vips-7.11/gather.c
> 
> Run it with:
> 
>   gather output.tiff in1.tiff in2.tiff ...
> 
> The input files need to be tiled TIFF. It just copies each one into
> the output file. If output.tiff is under 2GB, all is well. If
> output.tif goes just over 2GB, it becomes unreadable.
> 
>   john@mm-jcupitt2:~/pics$ tiffinfo output.tiff
>   output.tiff: Error fetching data for field "BitsPerSample".
> 
> Is this a bug? Or am I doing something horribly wrong? Thanks!

John,

Typically problems with file sizes between 2 and 4 GB relate to your
libtiff having gotten built with a "32bit" file io API.  On windows I
believe you need to ensure that tif_win32.c is used instead of tif_unix.c
(which works but is always 32bit with vc++ - I think).  On unix it is
important that the configure script identify special things required for
large file support.

When I run configure on my ubuntu 64 system I see:

checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... no

but large file stuff still works.  But I gather on some systems
some special macros may need to get defined.

OK, I've only got a weak grasp on how this magic works, but I
guess my point is that at least you need to tell us what your
build environment (operating system, compiler) is, and if on
unix you need to review your configure output for clues.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam@pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org