| AWARE [SYSTEMS] | Imaging expertise for the Delphi developer | |||||||
![]() |
TIFF and LibTiff Mailing List Archive | |||||||
LibTiff Mailing List
TIFF and LibTiff Mailing List Archive Contact
The TIFF Mailing List Homepage |
Thread2004.10.17 06:35 "Re: Any way to pass a byte based buffer in calling TIFFReadRGBAImageOriented?", by Andrey KiselevOn Wed, Oct 13, 2004 at 11:00:36AM -0500, Howard Xu wrote: > I am trying to use the latest libtiff library. But I have found that > APIs in reading TIFF files are requiring only a unit32 buffer > (tifBuffer) in the following call: > > TIFFReadRGBAImageOriented(tifFile, > width, height, > tifBuffer, > > ORIENTATION_TOPLEFT, 0) > > If I knew that the TIFF file to be loaded is a Black/White 1 > sample/bit data file, is there any way I can pass a byte (unsigned > char) buffer to the API so that the memory usage will be more > efficient? TIFFRGBAImage is a high level API. These calls always operate in the RGBA space and your 1-bit image will be converted in 8-bit quadruplet. To get access to the actual data contained in your image you should use TIFFReadScanline/TIFFReadEncodedStrip/TIFFReadTile functions. Andrey -- Andrey V. Kiselev Home phone: +7 812 5274898 ICQ# 26871517 |
|||||||