Sorry! I made a mistake. [message #30375] |
Fri, 26 April 2002 18:04  |
Weiqun Zhang
Messages: 3 Registered: April 2002
|
Junior Member |
|
|
In the .Xdefaults file, I should put "idl.gr_visual: TrueColor" instead
of "idl.gr_visual: True". Now it works. But there is still a problem I
don't understand.
(1) Which command is correct? "device, true=24" or "device,
TrueColor=24". In David Fanning's book, it is "device, TrueColor=24".
But I got error like this,
IDL> window
IDL> device, TrueColor=24
% Keyword TRUECOLOR not allowed in call to: DEVICE
I won't get error from "device, true=24", but it doesn't work.
Weiqun Zhang wrote:
> I am using IDL5.5 on RH Linux 7.2. I have some troubles with 8-bit
> images. "help, /device" tells me the visual class is "directcolor" and
> the depth is 24 bits. After displaying an 8-bit image using either tv or
> David Fanning's tvimage, the picture is in gray scale no matter what
> color table is loaded. If I click the IDL window and hold the mose,
> nothing happens. Then if I move the mouse so that the whole window moves
> a little bit, colors appear in the IDL window correctly, but other
> non-IDl windows have some strange colors. I know that the problem may be
> solved if I change the visual class to true. Unfortunately, I cannot
> change it.
>
> I have tried two ways.
> (1)device, true=24. After typing this command, I open a new window, then
> use "help, /device" to check it, it is still running direcrcolor.
> (2)I put "idl.gr_visual: True" and "idl.gr_depth: 24" in my .Xdefaults.
> Then Below message appears when I try to open a new window.
> IDL> window
> % WINDOW: X Windows resource "idl.gr_visual" has invalid value: True.
>
> Please help me! Thanks a lot!
>
> Belows are some information which might be helpful.
>
> IDL> window
> IDL> help,/device
> Available Graphics Devices: CGM HP LJ NULL PCL PRINTER PS REGIS TEK X Z
> Current graphics device: X
> Server: X11.0, The XFree86 Project, Inc, Release 40100000
> Display Depth, Size: 24 bits, (1400,1050)
> Visual Class: DirectColor (5)
> Bits Per RGB: 8 (8/8/8)
> Physical Color Map Entries (Used / Total): 256 / 256
> Colormap: Private, 16777216 colors. Translation table: Bypassed
> Graphics pixels: Decomposed, Dither Method: Ordered
> Write Mask: 16777215 (decimal) ffffff (hex)
> Graphics Function: 3 (copy)
> Current Font: <default>, Current TrueType Font: <default>
> Default Backing Store: Req from Server.
> Window Status: ---------------------
> id typ( x, y, backing store) id typ( x, y, backing
> store)
> 0: Win( 640, 512, Req from Server)
>
> ----------------------
>
> $ xdpyinfo | more
> name of display: :0.0
> version number: 11.0
> vendor string: The XFree86 Project, Inc
> vendor release number: 40100000
> XFree86 version: 4.1.0
> maximum request size: 4194300 bytes
> motion buffer size: 256
> bitmap unit, bit order, padding: 32, LSBFirst, 32
> image byte order: LSBFirst
> number of supported pixmap formats: 7
> supported pixmap formats:
> depth 1, bits_per_pixel 1, scanline_pad 32
> depth 4, bits_per_pixel 8, scanline_pad 32
> depth 8, bits_per_pixel 8, scanline_pad 32
> depth 15, bits_per_pixel 16, scanline_pad 32
> depth 16, bits_per_pixel 16, scanline_pad 32
> depth 24, bits_per_pixel 32, scanline_pad 32
> depth 32, bits_per_pixel 32, scanline_pad 32
> keycode range: minimum 8, maximum 255
> focus: window 0x1a00012, revert to Parent
> number of extensions: 26
> BIG-REQUESTS
> DOUBLE-BUFFER
> DPMS
> Extended-Visual-Information
> FontCache
> GLX
> LBX
> MIT-SCREEN-SAVER
> MIT-SHM
> MIT-SUNDRY-NONSTANDARD
> RENDER
> SECURITY
> SGI-GLX
> SHAPE
> SYNC
> TOG-CUP
> XC-APPGROUP
> XC-MISC
> XFree86-Bigfont
> XFree86-DGA
> XFree86-Misc
> XFree86-VidModeExtension
> XInputExtension
> XKEYBOARD
> XTEST
> XVideo
> default screen number: 0
> number of screens: 1
>
> screen #0:
> dimensions: 1400x1050 pixels (404x303 millimeters)
> resolution: 88x88 dots per inch
> depths (7): 24, 1, 4, 8, 15, 16, 32
> root window id: 0x31
> depth of root window: 24 planes
> number of colormaps: minimum 1, maximum 1
> default colormap: 0x20
> default number of colormap cells: 256
> preallocated pixels: black 0, white 16777215
> options: backing-store NO, save-unders NO
> largest cursor: 32x32
> current input event mask: 0x5a20bd
> KeyPressMask ButtonPressMask ButtonReleaseMask
> EnterWindowMask LeaveWindowMask PointerMotionHintMask
> ButtonMotionMask StructureNotifyMask SubstructureNotifyMask
> SubstructureRedirectMask PropertyChangeMask
> number of visuals: 4
> default visual id: 0x23
> visual:
> visual id: 0x23
> class: TrueColor
> depth: 24 planes
> available colormap entries: 256 per subfield
> red, green, blue masks: 0xff0000, 0xff00, 0xff
> significant bits in color specification: 8 bits
> visual:
> visual id: 0x24
> class: TrueColor
> depth: 24 planes
> available colormap entries: 256 per subfield
> red, green, blue masks: 0xff0000, 0xff00, 0xff
> significant bits in color specification: 8 bits
> visual:
> visual id: 0x25
> class: DirectColor
> depth: 24 planes
> available colormap entries: 256 per subfield
> red, green, blue masks: 0xff0000, 0xff00, 0xff
> significant bits in color specification: 8 bits
> visual:
> visual id: 0x26
> class: DirectColor
> depth: 24 planes
> available colormap entries: 256 per subfield
> red, green, blue masks: 0xff0000, 0xff00, 0xff
> significant bits in color specification: 8 bits
>
|
|
|