Re: 16-bit tiffs [message #11094 is a reply to message #11092] |
Sat, 14 March 1998 00:00  |
davidf
Messages: 2866 Registered: September 1996
|
Senior Member |
|
|
Deb Summa (summa@lanl.gov) writes:
> How does one write a 16-bit TIFF image in IDL? (Can this be done at all
> in IDL?)
Using IDL? Yes. Using built-in IDL routines? I don't think so.
> READ_TIFF will import a 16-bit TIFF image into an INT array just fine,
> but WRITE_TIFF reduces the aforementioned INT array to a BYTE array and
> writes out an 8-bit TIFF. I'd like to be able to maintain the dynamic
> range present in the original image. Do i have to turn the whole thing
> into a 24-bit image first? (and how does one do that if that's what has
> to be done?)
The more I've thought about this question (and I woke up at
4:30 this morning thinking about it, if you can believe that!)
the more I think it is entirely the wrong question.
For example, I don't know what "maintain the dynamic range
present in the original image" means. What "dynamic range"?
Of the *displayed* image? Then the dynamic range is dictated
by your display hardware, not the image data.
Your display is capable of only so many colors, say 256.
No matter what the range of the actual image data, you
will see the data in that many colors. Certainly the dynamic
range is not preserved in this abstraction. Believing that
what you see on the display is really your data is similar to
believing that the word "love" is the same as the feeling.
I may be entirely wrong about this, but I don't normally think
of the TIFF data format as a format that is particularly
useful for storing the "dynamic range" of data. I think of
it as a useful format for storing the "color abstraction" of
data. Typically, for display on some colleague's machine.
If I really wanted to preserve the dynamic data range, I think
I would be using something like HDF, where I could store the
actually data AND its color abstraction (in a palette, for
example).
Anyway, my two cents worth.
Cheers,
David
-----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438
Coyote's Guide to IDL Programming: http://www.dfanning.com/
|
|
|