AWARE SYSTEMS
TIFF and LibTiff Mail List Archive

Thread

2008.03.29 04:18 "[Tiff] TIFFReadRawStrip buffer data type", by James Sumners
2008.03.29 06:05 "Re: [Tiff] TIFFReadRawStrip buffer data type", by Bob Friesenhahn
2008.03.29 11:44 "Re: [Tiff] TIFFReadRawStrip buffer data type", by James Sumners
2008.03.29 15:41 "Re: [Tiff] TIFFReadRawStrip buffer data type", by Bob Friesenhahn
2008.03.29 16:26 "Re: [Tiff] TIFFReadRawStrip buffer data type", by James Sumners
2008.03.29 14:58 "Re: [Tiff] TIFFReadRawStrip buffer data type", by Frank Warmerdam
2008.03.29 16:29 "Re: [Tiff] TIFFReadRawStrip buffer data type", by James Sumners
2008.03.29 16:51 "Re: [Tiff] TIFFReadRawStrip buffer data type", by Bob Friesenhahn
2008.04.24 14:16 "Re: [Tiff] TIFFReadRawStrip buffer data type", by James Sumners

2008.03.29 16:51 "Re: [Tiff] TIFFReadRawStrip buffer data type", by Bob Friesenhahn

That makes a little sense. I was reading the image into a char buffer before, but got the feeling that I wasn't working with the correct values. I didn't think about an unsigned char. I'll give that a try and see how it works for me.

The only time there is benefit to using something other than an 'unsigned char' buffer type is when the bits per sample is 16, 32, or 64 and the data is presented the same as the CPU's native respresentation. Otherwise the data is packed in bitwise "natural" (MSB) order and needs to be unpacked using bit shifts/masks or some other approach.

Bob
======================================
Bob Friesenhahn
bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/