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

Home » Public Forums » archive » Re: Color Postscript output
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: Color Postscript output [message #3388 is a reply to message #3384] Thu, 12 January 1995 07:31 Go to previous message
thompson is currently offline  thompson
Messages: 584
Registered: August 1991
Senior Member
spencer@jhs.nrl.navy.mil (John Spencer) writes:

> I'm trying to make a color postscript file from IDL version
> { mipseb IRIX 3.5.1} on an SGI running Irix 5.2.

> IDL> set_plot,'PS' ; turn on postscript
> IDL> device,/color ; enable color (RM: 3-31)
> IDL> loadct,12 ; load a color table
> IDL> print,!d.n_colors
> 256
> IDL> device,color=0 ; turn off colors
> IDL> print,!d.n_colors
> 256

I've run into this before. IDL always thinks that PostScript devices have 256
colors. In color mode this makes sense. In non-color mode it also makes sense
because one can have up to 256 shades of grey.

It would make a certain amount of sense if the value of !D.N_COLORS reflected
the value of BITS_PER_PIXEL which can be other values besides 8, but it
doesn't.

> This, plus my inability to find a color table that makes colors
> come out in any postscript reader/printer I have, leads me to
> believe I'm confused. Can someone help?

I don't understand this second question. If you say DEVICE,/COLOR and
LOADCT,12 you should be able to create a color PostScript file that is then
compatible with any color PS printer you might have. Most PostScript viewers
such as ghostview or xpsview should also be capable of showing you the colors.
Maybe you can clarify the second part of your question.

Bill Thompson
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Overlaying axes on an image?
Next Topic: RANDOMU bug?

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

Current Time: Fri Oct 10 15:00:17 PDT 2025

Total time taken to generate the page: 0.87975 seconds