colors... again [message #23495] |
Thu, 25 January 2001 17:04 |
T Bowers
Messages: 56 Registered: May 1998
|
Member |
|
|
I thought I understood colors in IDL. If I create a color plot in a direct
graphics window
then tvrd() and immediately tv it back, how come the colors are not right?
E.g.:
device, decomposed=0 & loadct, 13 & window
map_set, 30, -89, LIMIT=[27, -92, 33, -86], GRID=1
map_continents, /coasts, color=155, HIRES=hires ;GREEN
map_continents, /rivers, color=200, HIRES=hires ;YELLOW
;store the window's image
mapImage = tvrd()
;print the unique color indices that are in this image.
;should print 0 155 200 255 for black, green, yellow, and red in this color
table
IDL> print, mapImage[UNIQ(mapImage, SORT(mapImage))]
0 255
Why only the 2 colors black and red??
tv, mapImage
shows it's true.
thanks
tb
|
|
|