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

Home » Public Forums » archive » Re: Map_Image()
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: Map_Image() [message #47088 is a reply to message #47074] Fri, 20 January 2006 04:41 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Sheldon writes:

> As my IDl edification continues, let me express my gratitude to those
> of you who have shared your knowledge, and sometimes wit, with me :<).
> After going through plot(), I have arrived at MAP_IMAGE(). Some stuff
> is straight forward and I know that many of you know this stuff like
> the back of your hands; so, can someone please explain a little more in
> detail what these two arguments to map_image() are?

An image, when it is warped into a map projection space,
does not take up the entire window, but only a portion
of it.

warp = Map_Image(image, xx, yy, xs, ys)

The four positional parameters to the right of the
original image tell you how to put the smaller
warped image into the larger window. The first
two of the parameters (xx,yy) locate the lower-left edge
of the warped image in pixel units. The second two
of the parameters (xs,ys) tell you the size of the
image in pixel units. You want to use all four of
the parameters to place or locate the image on
the map projection in the window:

TV, warp, xx, yy, XSIZE=xs, YSIZE=ys

The XSIZE and YSIZE parameters are not used when you
issue the TV command on your display device (a pixel
is a defined size there), but is critical if you want
the warped image to show up in the correct location
in PostScript, where pixel sizes are flexible. It
does no harm to write the TV command as above, so
it is always done this way for warped images.

The notion of "upon return" is IDL shorthand for
saying that these variables are *output* variables,
not input variables. That is to say, then the
procedure or function *returns*, these variables
have valid information, but not when they are called.
You need to provide a variable to capture the output,
otherwise IDL has nothing to return the information in.

You can see how to use Map_Image in this article:

http://www.dfanning.com/graphics_tips/toms_tutorial.html

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Problem with reading IDL written binary file....corrupt values?
Next Topic: Re: cool way to determine durations in time series

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

Current Time: Sun Oct 12 13:31:21 PDT 2025

Total time taken to generate the page: 1.52262 seconds