2006.04.14 14:59 "[Tiff] TIFFReadScanline with JPEG compression", by Jason Summers
I'm having trouble getting libtiff's TIFFReadScanline function to work with:
- grayscale old-JPEG images. Some scanlines succeed, but others fail with a "LibJpeg: Improper call to JPEG library in state 0" error. This is with the latest libtiff from CVS. It works fine if I use TIFFReadEncodedStrip.
- color new-JPEG images when using JPEGCOLORMODE_RGB. This used to work for me, but it has stopped working in recent versions of libtiff, at least for some images such as the quad-jpeg.tif sample. Using TIFFReadEncodedStrip (without JPEGCOLORMODE_RGB) works fine.
- I know I may not be giving enough details. But is TIFFReadScanline even *supposed* to work in these cases, or should I just give up and always use the memory-hungry TIFFReadEncodedStrip?