[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: color table trouble
- Subject: Re: color table trouble
- From: davidf(at)dfanning.com (David Fanning)
- Date: Fri, 2 Apr 1999 09:46:39 -0700
- Newsgroups: comp.lang.idl-pvwave
- Organization: Fanning Software Consulting
- References: <7e2nh8$h5p$1@nnrp1.dejanews.com> <MPG.116e9850187e04d2989745@news.frii.com> <MPG.116e9f6f6c644558989746@news.frii.com>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:14198
Well, I'm full of ideas today... :-)
I wrote just a moment ago:
> But here is the real kicker reason for me: if I
> *care* about displaying my 24-bit images correctly
> (and color decomposition really only makes sense
> if I have 24-bit images, it seems to me) then--as
> I posted last week--I HAVE to set the DECOMPOSED
> keyword anyway:
>
> Device, Decomposed=1
> TV, image24
>
> If I don't do this, then I run the risk that my
> image will not be displayed properly, since with
> color decomposition off, ALL values, even those in
> 24-bit image values, are run through the color table.
Even this is not the whole story, because--of course--
the DECOMPOSED keyword is not an allowed keyword for
any graphics device EXCEPT X, Win, and Mac. So if I
want to write code that *always* works in *every*
environment (and who among us doesn't?) then I have
to wrap EVERY single TV command with something like
this:
CASE StrUpCase(!D.Name) OF
'WIN' : Device, Decomposed=1
'MAC' : Device, Decomposed=1
'X' : Device, Decomposed=1
ELSE:
ENDCASE
TV, image24, TRUE=1
Even at $100/hour I find it hard to type that much code
each time I want to display an image. :-(
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155