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

Home » Public Forums » archive » Re: map_proj_* help
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_proj_* help [message #66796 is a reply to message #66794] Mon, 08 June 2009 05:29 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Ken Mankoff writes:

> Images from the NSIDC. I noticed you used "we" when referring to them.
> Has coyote moved south from Fort Collins and has an affiliation?

Too many children in college. :-(

> Also, I am familiar with a map datum and other terms, although
> obviously not familiar enough to solve this particular problem. But
> are you sure IDL won't convert datums? If you define a "from" and "to"
> on different datums (datii?) and projections in MAP_PROJ_INIT, and
> then in MAP_PROJ_IMAGE use IMAGE_STRUCTURE=from, MAP_STRUCTURE=to,
> this wouldn't work? Never tried it but it seems like it should.
> Anyway, WGS84 is common enough, and my errors are currently large
> enough, that I don't think datum is (yet) the issue.

I don't think IDL does datum shifts. ENVI does a three-point
datum shift, but not the more comprehensive 8-point (?)
datum shifts you can get with more sophisticated map
projection software. (This is still a little blurry for
me, so maybe someone who knows can elaborate.)

> http://nsidc.org/data/iceshelves_images/pine.html

Well, here is how I would orient this image. Trying
to put continental boundaries on Antarctica is sketchy.
But this will certainly give you a map data coordinate
system that you can draw your own map features on.

;**********************************************************
file = 'G:\data\pine_2009084_1545_modis_ch02.png'
image = Read_PNG(file)
image = Reverse(image, 2) ; Put the (0,0) point in UL.

; Display map in window.
pos = [0.1, 0.1, 0.9, 0.9]
TVImage, image, POSITION=pos, /KEEP_ASPECT, /NOINTERP, /ERASE

; Set up Map Projection. Polar Stereographic, WGS-84 Datum.
map = Map_Proj_Init(106, DATUM='WGS 84', CENTER_LATITUDE=-90)

; Convert corners to XY coordinates. Clockwise, from UL.
lons = [-113.594373, -98.868027, -98.568614, -117.004071]
lats = [-71.998860, -72.492200, -76.115095, -75.491196]
xy = Map_Proj_Forward(lons, lats, MAP_STRUCTURE=map)

; Set up map coordinate space for drawing on the map.
Plot, [xy[0,0], xy[0,1]], [xy[1,0], xy[1,2]], $
XStyle=5, YStyle=5, /NoData, POSITION=pos, /NOERASE

; Draw continental outlines.
; Map_Continents, MAP_STRUCTURE=map, /COASTS, /HIRES, /FILL

; Draw map grids.
Map_Grid, MAP_STRUCTURE=map, LONDEL=2.5, LATDEL=0.25, $
LATLAB=-105, LONLAB=-72, /LABEL
;*********************************************************** ****

Of course, in the case of NSIDC image, I *always* believe the
published map corners. ;-)

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: How to edit the file of classification
Next Topic: Re: too many elements

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

Current Time: Wed Oct 08 18:09:25 PDT 2025

Total time taken to generate the page: 0.00271 seconds