I am unable to display pseudo-color images correctly running idl 5.5.
I run the following code:
device,decomposed=0,pseudo=8
red=bytarr(256)
green=bytarr(256)
blue=bytarr(256)
up1=bindgen(101)*2.55
red(0)=up1
green(0)=up1
blue(0)=up1
up2=bindgen(34)*7.73
up3=up2(1:32)
down2=rotate(up2,2)
coffset1=128
red(coffset1)=[0,replicate(0,34),up3,replicate(255,34)]
green(coffset1)=[0,up2,replicate(255,32),down2]
blue(coffset1)=[0,down2,replicate(0,66)]
coffset2=101
red(coffset2)= [255,255, 0, 50,64,84,255]
green(coffset2)=[0, 255,255, 50,64,84,255]
blue(coffset2)= [0, 0, 0,255,64,84,255]
tvlct,red,green,blue
tmp=indgen(256)#replicate(1,256)
tv,tmp
I run idl on a LINUX box that supports 24 bit color. The image should
consist of vertical bands of color, greys from black to white on the
left, blue, green, yellow and red on the right with several narrow
bands of various colors and a broad band of black in between. The
colors are correct when run under idl 5.3, although I do get the error
message
% Unsupported X Windows visual (class: PseudoColor, depth: 8).
Substituting default (class: TrueColor, Depth: 24).
When I run the code on the same hardware running idl 5.5, I get the
same error message, but the colors are incorrect; the grey area is
yellow, the blue to red region is red, yellow, and green, and the
narrow bands are also incorrect.
The code is embedded in a large program, so I don't want to rewrite
it using 24 bit color.
Any ideas for a quick fix?
Thanks in advance.
--
Alan Barnett
2500 Jennings Rd
Silver Spring, MD 20902
301 949 2297
|