[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Postscript Output
- Subject: Re: Postscript Output
- From: davidf(at)dfanning.com (David Fanning)
- Date: Mon, 31 Jan 2000 10:06:38 -0700
- Newsgroups: comp.lang.idl-pvwave
- Organization: Fanning Software Consulting
- References: <3895B6FF.9274B7BE@stud.uni-karlsruhe.de>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:18192
Ingo (ingo.meisel@stud.uni-karlsruhe.de) writes:
> I'm trying to export the contents of an IDL graphics window to a
> postscript file. This is the IDL code I've been using so far in a
> subroutine:
> 
> set_plot,'PS'
> 
> device, /color, file='file.ps'
> 
> tv,image   ;the variable image contains the pixel raster to store
> 
> device, /close
> 
> A postscript file is generated, however, the page is empty.
> What is wrong? Who can help me?
The page is empty!? I would have expected lousy output,
given the way you have configured the PostScript device,
but I wouldn't have expected the page to be empty.
I'm going to guess your image data isn't scaled into
256 values. Try something like this:
   thisDevice = !D.Name
   Set_Plot, 'PS'
   Device, Color=1, Bits_per_Pixel=8, File='image.ps'
   TV, BytScl(image)
   Device, /Close_File
   Set_Plot, thisDevice
You might also want to have a look at the Producing Perfect
PostScript Output section of my IDL Programming Tips 
page for a number of other PostScript tips.
   http://www.dfanning.com/documents/tips.html#PostScript
Cheers,
David
-- 
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155