comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: changing the color map without having to re-load an image
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: changing the color map without having to re-load an image [message #29976 is a reply to message #29973] Wed, 03 April 2002 01:46 Go to previous messageGo to previous message
David Burridge is currently offline  David Burridge
Messages: 33
Registered: January 1998
Member
Hi Marc,

"Marc Sauvage" <msauvage@cea.fr> wrote in message
news:59bc2798.0204030112.6e521c7e@posting.google.com...
> Hi there,
>
> since I recently changed my work environment from an X-terminal
> running on a solaris network to a mac on OSX with Xfree86, I'm
> experiencing a strange problem with colors: I cannot modify the color
> map (e.g. with xloadct, or by loading a new table with the command
> line) and have these changes apply to the already displayed images.
> The changes will only affect the images I load after the change.
>
> I never experienced this problem in my previous configuration. The
> problem appears to be connected to the way I'm working now: I'm using
> Xdarwin (basically that's Xfree86 compiled form Mac OS X) to start an
> X session on the mac, then I connect to a solaris machine and run IDL
> there on remote.
>
> At first I couldn't even use colors, but searching around made me
> stumble on
>
> device,decompose=0
>
> Which solves this problem. So now I can use colors, any color table,
> in fact. I can modify the color table with xloadct, and I see the
> color table changing in the xloadct widget, but these changes do not
> affect the already opened graphics window and I have to reload the
> images to see the changes (I' ve tried setting retain to 2 but I don't
> think this addresses my problem). This is a pain because in my field,
> astronomy, I have to do this almost all the time to actually see
> what's in the images, and explore the structure of the objects.
>
> I checked on both the Mac and the unix server which types of visual
> were supported (with xpdyinfo) and apparently the same types are
> supported on both side. Currently I'm set to true_color. Also worth
> knowing: my version of IDL is 5.4.
>
> Anyone with ideas on how to solve this problem is welcome.
>
> Marc.

You are going to get a *ton* of answers to this when the USA wakes up in a
few hours - most of them far more expert than me:-) But, in case you're in
more of a hurry ....

It sounds to me like you were using 8-bit color before and now you've moved
up to 24-bit. My understanding of the decomposed=0 is that it sets up a
translation table so that 8-bit colormaps (e.g. those used by xloadct) will
work. Until then you normally get shades of red as you'll be accessing the
red part of the rgb colormap. The downside of this is that it makes the
image display a two-step process, so you have to redraw to reapply color
changes. This is why "smart" windows (that know how to redraw themselves)
and objects (ditto) have been popular for a while.

If you're really desperate, you might try downgrading the number of colors
your windows supports to 256 (yuk!), but before you do - the guru for this
stuff is Dave Fanning (who will no doubt pick up your message soon) and you
should *definitely* look at his site for utilities and programs in this area
(www.dfanning.com).

Good luck!

Dave
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Vectorized STRMID ( was Re: Selecting odd/even numbered files)
Next Topic: testcase

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 16:49:43 PDT 2025

Total time taken to generate the page: 0.00392 seconds