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
December 2004

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

2004.12.07 11:25 "Fetching pixel data from 4bit tiff", by Dan Field
2004.12.07 11:32 "Re: Fetching pixel data from 4bit tiff", by Joris Van Damme
2004.12.07 11:38 "Re: Fetching pixel data from 4bit tiff", by Dan Field
2004.12.07 11:48 "Re: Fetching pixel data from 4bit tiff", by Joris Van Damme
2004.12.07 11:57 "Re: Fetching pixel data from 4bit tiff", by Dan Field
2004.12.07 12:21 "Re: Fetching pixel data from 4bit tiff", by Joris Van Damme
2004.12.07 13:02 "Re: Fetching pixel data from 4bit tiff", by Joris Van Damme
2004.12.07 14:50 "Re: Fetching pixel data from 4bit tiff", by Dan Field
2004.12.07 15:52 "Re: Fetching pixel data from 4bit tiff", by Bob Friesenhahn
2004.12.07 16:46 "Re: Fetching pixel data from 4bit tiff", by Dan Field
2004.12.07 17:04 "Re: Fetching pixel data from 4bit tiff", by Bob Friesenhahn
2004.12.07 20:00 "Re: Fetching pixel data from 4bit tiff", by Joris Van Damme
2004.12.07 20:41 "Re: Fetching pixel data from 4bit tiff", by Bob Friesenhahn

2004.12.07 11:38 "Re: Fetching pixel data from 4bit tiff", by Dan Field

> > Hi. I'm new to libtiff and I'm no C guru either, so please excuse my
> > ignorance here .
>
> Using LibTiffDelphi?

No just good old libtiff C library, I'm just rusty.

> > I am trying to get pixel data from a 4bit TIFF. I can use
> > TIFFReadRGBAImage, TIFFReadR, TIFFReadG, TIFFReadB, TIFFReadA but surely
> > these will not provide the correct data for a 4bit image?
>
> Oh but yes, it should. TIFFReadRGBAImage always returns 32bit RGBA data,
> regardless of source colorspace and bitdepth. (Which is its greatest drawback,
> and its greatest convinience.)

Ah, excelent. I was starting to doubt my data. So if it converts from 
greyscale to RGBA, surely the R, G, B values would all be the same? eg

R=45
G=45
B=45

The data I'm pulling out doesn't fit this pattern at all:

eg:

R       G        B

71      202     94
14      209     94
213     215     94
156     222     94
99      229     94

Thanks for the fast response Joris :)

-- 
Dan Field <dof@llgc.org.uk>            http://www.cymruarywe.org/
                                       http://www.walesontheweb.org/
     Developer / Sysadmin
     Llyfyrgell Genedlaethol Cymru