[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 8-bit vs. 24-bit color on Windows



William Thompson wrote:
> I know this question has been asked many times before, but I'm afraid I don't
> remember what the answer is.  Is there any way to convince IDL to use 8-bit
> pseudo-color on a Windows computer with a 16-bit or higher display?  I know
> that in other operating systems this is done by using
> 
>         DEVICE,PSEUDO_COLOR=8
> 
> However, this is not supported under Windows.  I tried
> 
>         DEVICE,DECOMPOSED=0
> 
> which the documentation claims will make routines work like they did before,
> but this doesn't appear to be the whole story.  With DECOMPOSED=0, data will
> come up with the correct color, but only if they are displayed after the color
> table is loaded.  This is unacceptable.  There must be another step to convince
> IDL to use 8-bit pseudo-color, and if there isn't then RSI must address this.
> 
> I've checked David Fanning's Coyote Guide (http://www.dfanning.com/), but the
> only suggestion I could find there that meets my needs is to set Windows to run
> at 256 colors.  I'm perfectly happy to do that, but it would be nice to be able
> to use 16-bit or 24-bit for those programs which need it, and 8-bit color for
> IDL.  This is possible in other operating systems; can it be done in Windows?

When using IDL under Windows with a 24 bit display setting, the only way
around this problem is to re-display your graphic after changing the
color table. That's why David's XCOLORS program
(http://www.dfanning.com/programs/xcolors.pro) includes a keyword which
enables you to notify an external event handler that the color table has
changed.

BTW I've noticed image display problems (especially with grey scale
images) under Windows when using a 16 bit display setting. The problems
do not appear in 8 bit or 24 bit display modes (which are the modes
supported by IDL).

Cheers,
Liam.

---
Liam E. Gumley
Space Science and Engineering Center, UW-Madison
1225 W. Dayton St., Madison WI 53706, USA
Phone (608) 265-5358, Fax (608) 262-5974
http://cimss.ssec.wisc.edu/~gumley