| 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 |
Thread2012.01.04 15:24 "Re: reading rgb values from 16 bits tif images", by Bob FriesenhahnOn Wed, 4 Jan 2012, Martin Alegre wrote: > Hi Bob, > > Thanks for your suggestions on the high-level libraries. At the beginning, > I was thniking to use Magick++ > for my application, but it seemed to me that it was going to be more > faster to integrate the libtiff > library into my code, also due to time constraints. If you have any > illustrations on how to use libtiff > for 16bits images, it will be great or if you also have some good > webpointers where I could get more > information? I found a very illustrative webpage on how to use libtiff > (http://bitmiracle.com/libtiff/help/samples.aspx), but it was mainly for > C#, and I'm currently working > with C++. It makes a huge difference if you plan to accept arbitrary TIFF files written by some other software or if you only plan to accept a very limited set of TIFF formats. If the former, then you should expect to do quite a lot of development (e.g. weeks, months). You can use TIFFReadRGBAStrip() to access strip-oriented files or TIFFReadTile() for tile-oriented files. These interfaces provide "raw" decompressed + native-endian-swapped pixel sample data. The swapping to native endian is only done if the sample bits are evenly divisible by 8 (e.g. 16-bit "short" is swapped to native format). Bob -- Bob Friesenhahn bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/ |
|||||||