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
February 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.02.11 06:07 "facing problems with writing compressed tiff image strips.", by Priyanshu Sharma
2005.02.14 10:18 "make the libtiff library compression enabled??", by Priyanshu Sharma
2005.02.14 10:53 "Re: make the libtiff library compression enabled??", by Joris Van Damme
2005.02.16 04:09 "Re: make the libtiff library compression enabled??", by Priyanshu Sharma
2005.02.14 18:08 "Re: make the libtiff library compression enabled??", by <melser.anton@gmail.com>

2005.02.14 18:08 "Re: make the libtiff library compression enabled??", by <melser.anton@gmail.com>

Priyanshu Sharma wrote:
> i have figured out my problem and now i am able to extract a single
> page from a tiff file but it works only for the uncompressed images.
> 
> i guess i have not enabled the compression tag while building the
> libtiff library. can any one tell me how i can do that i.e. what all
> flags i have to specify under the head EXTRAFLAGS label.

I pulled my hair out for ages trying to do some similar stuff with 
libtiff and just ended up doing a straight copy. If you can get your 
data into a single strip (with libtiff or other) then the code is very 
simple indeed. You just read the stripoffset tag and stripbytecounts and 
read from the file into a buffer and write out to the new file (making 
sure you put in stripbytecounts and your desired stripoffset). You could 
also copy each strip over but that gets more complicated. You need to 
make sure you know the format though, cos as someone else mentions, if 
you miss copying an important tag you can have very subtle errors creep 
in. My c is very weak and for this sort of control it was much simpler 
to do it myself.

Make sure you read the very readable standard (google for tiff6.pdf) 
thoroughly a few times first and during and you'll be fine.

Cheers
Antoine