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
January 2005

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

2005.01.29 15:42 "almost finished hacking libtiff into a convivial shape", by <melser.anton@gmail.com>
2005.01.30 09:00 "Re: almost finished hacking libtiff into a convivial shape", by Ross A Finlayson
2005.01.30 10:00 "Re: almost finished hacking libtiff into a convivial shape", by <melser.anton@gmail.com>
2005.01.30 16:34 "Re: almost finished hacking libtiff into a convivial shape", by <melser.anton@gmail.com>
2005.01.30 23:30 "Re: almost finished hacking libtiff into a convivial shape", by <sherlog@t-online.de>
2005.01.31 00:17 "Re: almost finished hacking libtiff into a convivial shape", by <melser.anton@gmail.com>

2005.01.29 15:42 "almost finished hacking libtiff into a convivial shape", by <melser.anton@gmail.com>

Hi,

I have managed to disable/change the things I need except for one - the 
offset to the first IFD. I need it to be 8. I have replaced the lines in 
tif_dirwrite.c:

    tif->tif_diroff = (TIFFSeekFile(tif, (toff_t) 0, SEEK_END)+1) &~ 1;
    diroff = tif->tif_diroff;

for

    if (tif->tif_header.tiff_diroff == 0)
        tif->tif_diroff = 8;
    else
        tif->tif_diroff = (TIFFSeekFile(tif, (toff_t) 0, SEEK_END)+1) &~ 1;

    diroff = 8; //tif->tif_diroff;

And it seems to be working to a point. The problem is that it borks the 
first couple of hundred scanlines. When I open with the gimp (2.0) it 
tells me

...
Tiff: /home/antt/programming/tiff-3.7.1/tools/well.tif: Premature EOL at 
scanline 199 (got 0, expected 2248)

Tiff: /home/antt/programming/tiff-3.7.1/tools/well.tif: Premature EOL at 
scanline 200 (got 2247, expected 2248)

Tiff: /home/antt/programming/tiff-3.7.1/tools/well.tif: Bad code word at 
scanline 201 (x 0)

Tiff: /home/antt/programming/tiff-3.7.1/tools/well.tif: Premature EOL at 
scanline 201 (got 0, expected 2248)

Tiff: /home/antt/programming/tiff-3.7.1/tools/well.tif: Line length 
mismatch at scanline 202 (got 2249, expected 2248)

Anyone got any ideas on this?
Cheers
Antoine