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

Home » Public Forums » archive » Re: TV/postscript problem
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: TV/postscript problem [message #13388] Thu, 05 November 1998 00:00 Go to previous message
davidf7203 is currently offline  davidf7203
Messages: 12
Registered: August 1998
Junior Member
R Balthazor <r.balthazor@sheffield.ac.uk> writes:

> I'm running a program with the general form shown below. It cycles over
> 20 timesets of two datasets, each time reading them both in and
> displaying one as a false-color image on a map projection and then
> displaying the second as a contour image overlaid on it. Each time it
> flashes up the completed image satisfactorily on the X-windows, and the
> postscript file builds up until it is 20 pages long.
>
> However, each page of the postscript file is a horrible two-tone mess of
> black and white, looking like it is an 'overexposed' photograph and
> nothing like what was on the screen; and moreover, the TV,imageset is
> larger than and displaced from the desired position.
>
> What have I done wrong?

Several things. You might want to have a look at the
section of my web page called "Producing Perfect PostScript
Output" for more detailed information. (Or you could
read the equivalent chapter in my book for even *more*
information. :-)

> I'd be very grateful for any suggestions; I presume the problem is in
> the postscript writing.

Well, most computer programs only do what they are told. :-)


> DEVICE,file='image.ps',/LANDSCAPE,XSIZE=27,YSIZE=17,$
> XOFFSET=2,YOFFSET=28.5,/TIMES,/COLOR

Here is the first problem. You seem to want color output,
but getting what you expect will be nearly impossible unless
you also set the BITS_PER_PIXEL keyword to 8.

> MAP_SET,(arguments)
> imageset1=MAP_IMAGE(dataset1,startx,starty,other arguments)
> TV,imageset1,startx,starty
> CONTOUR,dataset2,/OVERPLOT

Here is the next problem. You seem to be dismissing the
"other arguments", but I suspect that it is the misuse
(more likely non-use) of these other arguments that is
doing you in. And in particular is causing your image to
be the wrong size.

MAP_IMAGE not only returns the starting coordinates of
the image, but the size of the image. You must use
these sizes on the TV command or you image will not
be the right size on your PostScript page. The commands
should look like this:

warped = Map_Image(image, xstart, ystart, xsize, ysize)
TV, warped, xstart, ystart, XSize=xsize, YSize=ysize

And may I suggest you test your program with one image
instead of 20. It will save you some time cooling your
heels by the water cooler while the printer chugs along. :-)

Cheers,

David

-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
[Message index]
 
Read Message
Read Message
Previous Topic: ROI stats?
Next Topic: Eigenvectors

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

Current Time: Sat Oct 11 05:52:59 PDT 2025

Total time taken to generate the page: 0.48141 seconds