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

Home » Public Forums » archive » 24 bit displays, private colormaps, and other things that keep my up
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
24 bit displays, private colormaps, and other things that keep my up [message #9904] Fri, 12 September 1997 00:00 Go to next message
Aviv Gladman is currently offline  Aviv Gladman
Messages: 8
Registered: August 1997
Junior Member
I don't mind the color flashing that results from a private colormap
using IDL/X windows, my problem is this: Why don't widgets use the same
colormap as the rest of IDL? In 8-bit pseudo-color mode (on my 24-bit
fvwm-managed X display), I can display an image using:

window
tvscl,image

and get the correct image colors only when I have the mouse on the image
(fine, I can deal with that). If I create a widget using:

base=widget_base()
draw=widget_draw(base)
widget_control,base,/realize
widget_control,draw,get_value=drawID
wset,drawID
tvscl,image

I get the wrong colormap, same as before, but if I put my mouse on the
widget, I don't get back the correct colormap. Like I said, I don't mind
the flashing, but does anyone know how to make sure that *all* IDL
windows use the same colormap?

Frustrated,

Aviv S. Gladman
Re: 24 bit displays, private colormaps, and other things that keep my up [message #9961 is a reply to message #9904] Fri, 19 September 1997 00:00 Go to previous message
David Foster is currently offline  David Foster
Messages: 341
Registered: January 1996
Senior Member
Aviv Gladman wrote:

> My basic problem seems to stem from the fact that
> IDL/Motif widgets use the shared colormap associated with the Motif/X root
> window, rather than using the private colormap associated with the
> pseudo-color IDL session. I can solve the problem by using a shared
> colormap for the entire session (say, Idl*colors=-5), but this
> considerably restricts the number of colors available to IDL.

Doesn't this just tell IDL to leave alone 5 colors which will be used
by the window system or other applications. That doesn't considerably
restrict the number of colors available.

I use IDL 5.0 on an Ultra with Solaris also, but with OpenWindows,
and I don't experience this problem.

--

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
David S. Foster Univ. of California, San Diego
Programmer/Analyst Brain Image Analysis Laboratory
foster@bial1.ucsd.edu Department of Psychiatry
(619) 622-5892 8950 Via La Jolla Drive, Suite 2240
La Jolla, CA 92037
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
Re: 24 bit displays, private colormaps, and other things that keep my up [message #9968 is a reply to message #9904] Thu, 18 September 1997 00:00 Go to previous message
Aviv Gladman is currently offline  Aviv Gladman
Messages: 8
Registered: August 1997
Junior Member
Well, I've received a number of suggestions from various sources, none of
which have been entirely useful (thanks for the suggestions, though!).
The IDL pseudo-color mode/widget colormap problem that I seem to have is
not fvwm dependent, which had been suggested by someone (I have the same
problem running olwm). True color mode is entirely unsatisfactory because
the redraw time on 3D image sets during thresholding procedures (where
the user varies the colormap in real-time to visually determine a threshold
level) is far too slow. My basic problem seems to stem from the fact that
IDL/Motif widgets use the shared colormap associated with the Motif/X root
window, rather than using the private colormap associated with the
pseudo-color IDL session. I can solve the problem by using a shared
colormap for the entire session (say, Idl*colors=-5), but this
considerably restricts the number of colors available to IDL. Does anyone
know how to force IDL widgets to use the IDL colormap rather than the
root window colormap?

I am using:

Sun Ultra 1, running fvwm or olwm, Solaris, IDL 5.0 (sunos/sparc), 24-bit
display, pseudo-color mode, private colormap (256 colors)

IDL> help, /device
Available graphics_devices: CGM HP LJ NULL PCL PRINTER PS REGIS TEK X Z
Current graphics device: X
Server: X11.0, Sun Microsystems, Inc., Release 3510
Display Depth, Size: 8 bits, (1280,1024)
Visual Class: PseudoColor (3)
Bits Per RGB: 8
Physical Color Map Entries (Used / Total): 256 / 256
Colormap: Private, 256 colors. Translation table: Enabled
Graphics pixels: Combined, Dither Method: Ordered
Write Mask: 255 (decimal) ff (hex)
Graphics Function: 3 (copy)
Current Font: <default>
Default Backing Store: Req from Server.


Thanks,

Aviv S. Gladman

On Thu, 18 Sep 1997, Christian Stoecklin wrote:

>
> Aviv Gladman wrote:
>> I get the wrong colormap, same as before, but if I put my mouse on the
>> widget, I don't get back the correct colormap. Like I said, I don't mind
>> the flashing, but does anyone know how to make sure that *all* IDL
>> windows use the same colormap?
>
> The problem is that you are in pseudo-color mode with pivate
> colormaps. You have to change in you .Xdefault:
>
>
> idl.gr_visual: TrueColor
> idl.gr_depth: 24
> Idl*colors: -5
>
> in this case idl is running in true-color mode with
> shared colormaps. But if you change the colormap
> you have to plot your image again to update the
> colors.
>
> I hope this helps,
>
> Christian Stoecklin
>
> --
> Christian Stoecklin (dipl.phys.ETH)
> Scientific Assistant, Image Science Group
> Swiss Federal Institute of Technology (ETH), Zuerich
> tel: +41-1-632 51 63 email: cstoeckl@vision.ee.ethz.ch
>
>
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Web-Based Image Processing Laboratory OPEN for FREE use...
Next Topic: Re: plotting contours thru saddle points

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

Current Time: Wed Oct 08 13:28:49 PDT 2025

Total time taken to generate the page: 0.00504 seconds