Re: working with colours [message #37648 is a reply to message #37647] |
Tue, 13 January 2004 08:14   |
Liam Gumley
Messages: 473 Registered: November 1994
|
Senior Member |
|
|
maarten" <user@domain.invalid> wrote in message
news:4003EF71.5070201@domain.invalid...
> I have a problem with working with colours. I have two datasets that
> will be layed on eachother. One of the datasets will be displayed in
> greyvalues, the other will have to be displayed in a blue-red activation
> colourscheme, transparancy isn't needed. I tried to divide the
> colourspace in two separate parts using the bytscl command. But then all
> the colours of my linux environment are changed. Is there a way to avoid
> this, and also to be able apply the colourscheme to just one window,
> leaving the other windows in greyscale?
Download my IMDISP program from
http://www.gumley.com/PIP/Free_Software.html
and try this:
;- Gray scale image
window, /free
loadct, 0, bottom=0, ncolors=64
imdisp, dist(256), bottom=0, ncolors=64
;- Blue/red image
window, /free
loadct, 11, bottom=64, ncolors=64
imdisp, dist(256), bottom=64, ncolors=64
If the colors don't turn out as expected, then exit IDL, and save the
following commands in a file named $HOME/idl_startup.pro:
if !version.os_family eq 'unix' then device, true_color=24
window, /free, /pixmap, colors=-10
wdelete, !d.window
device, decomposed=0, retain=2, set_character_size=[10, 12]
device, get_visual_depth=depth
print, 'Display depth: ', strcompress(depth)
print, 'Color table size: ', strcompress(!d.table_size)
Use this file as your IDL startup file by setting the IDL_STARTUP
environment variable, and start a new IDL session, e.g.
% setenv IDL_STARTUP $HOME/idl_startup.pro
% idl
Now try the image display commands again.
Cheers,
Liam.
Practical IDL Programming
http://www.gumley.com/
|
|
|