;+ ; NAME: ; worldbook_mapset ; ; PURPOSE: ; Mapping over the CIA worldbook maps ; ; DESCRIPTION: ; Set up for mapping over the CIA worldbook maps ; ; CALLING SEQUENCE: ; worldbook_mapset, map, _extra ; ; INPUTS: ; map - name of a map in ~/reference/maps/Earth/cia_factbook2004 ; KEYWORDS ; dir - alternate directory ; _extra - passes things on to map_set ; OUTPUTS: ; None ; REVISON HISTORY: ; 2005 Dec 31 Leslie A Young, SwRI ;- pro worldbook_mapset, fn, dir=dir, jpg=jpg, uvrange=uvrage, _extra=extra ; open the file if not keyword_set(dir) then begin dir = '~/reference/maps/Earth/cia_factbook2004/' end read_jpeg, dir+fn+'.jpg', jpg, /true ; display it sz = size(jpg) window, xs=sz[2], ys=sz[3], pixmap=pixmap tv, jpg, /true ; set the mapping case fn of 'south_america': begin limit=[-20.0, -89.5,$ ; lat, long on left edge 14.9, -60.5,$ ; lat lon on top edge -20.0, -30.5,$ ; lat lon on right edge -56.8, -60] ; lat lon on bottom edge lat0 = -21.0 ; latitude of center of ;lambert azimuthal equal area proj. lon0 = -60.0 ; longigude of same rot = 0 ; rotation xmarg = [9,9] ymarg = [5.2,9] map_set,lat0,lon0,rot, $, /lambert, $ ; lambert azimuthal equal area proj. limit=limit, $ ; limits to plot xmarg=xmarg,ymar=ymarg, $ ; margins in units of charsize /noerase, $ ; don't erase background _extra=extra end 'oceania': begin limit=[-47.3, $ ; lat min 112.3, $ ; lon min 28.5, $ ; lat max -122.8 ] ; lon max lat0 = 0 ; latitude of center of lon0 = 170.0 ; longigude of same rot = 0 ; rotation xmarg = [0,1] ymarg = [.7,1.4] map_set,lat0,lon0,rot, $, /mercator, $ ; lambert azimuthal equal area proj. limit=limit, $ ; limits to plot xmarg=xmarg,ymarg=ymarg, $ ; margins in units of charsize /noerase, $ ; don't erase background _extra=extra end 'south_america4x': begin limit=[-20.0, -89.5,$ ; lat, long on left edge 14.9, -60.5,$ ; lat lon on top edge -20.0, -30.5,$ ; lat lon on right edge -56.8, -60] ; lat lon on bottom edge lat0 = -21.0 ; latitude of center of ;lambert azimuthal equal area proj. lon0 = -60.0 ; longigude of same rot = 0 ; rotation xmarg = [9,9]*4 ymarg = [5.2,9]*4 map_set,lat0,lon0,rot, $, /lambert, $ ; lambert azimuthal equal area proj. limit=limit, $ ; limits to plot xmarg=[9,9],ymar=[5.2,9], $ ; margins in units of charsize /noerase, $ ; don't erase background _extra=extra end 'physical_world4d' : begin xmarg = [8.5,18.6] ymarg = [16,11.4] MAP_SET, /ROBINSON, 0,10,/noer, xmarg=xmarg, ymarg=ymarg, _extra=extra end else: begin end endcase ; convert xmarg, ymarg uvrange uvrange = [xmarg[0]*!d.x_ch_size, $ ; u min ymarg[0]*!d.y_ch_size, $ ; v min sz[2] - xmarg[1]*!d.x_ch_size, $ ; u max sz[3] - ymarg[1]*!d.y_ch_size ] ; v max end