Home | Categories | Alphabetical | Classes | All Contents | [ < ] | [ > ]

MAP_PROJ_INIT


Syntax | Return Value | Arguments | Keywords | Projection Keywords | Example | Version History | See Also

The MAP_PROJ_INIT function initializes a mapping projection, using either IDL's own map projections or map projections from the U.S. Geological Survey's General Cartographic Transformation Package (GCTP). GCTP version 2.0 is included with IDL.

Note
The !MAP system variable is unaffected by MAP_PROJ_INIT. To use the map projection returned by MAP_PROJ_INIT for direct or object graphics, use the MAP_PROJ_FORWARD and MAP_PROJ_INVERSE functions to convert longitude/latitude values into Cartesian (x, y) coordinates before visualization.

This routine is written in the IDL language. Its source code can be found in map_proj_init.pro in the lib subdirectory of the IDL distribution.

Syntax

Result = MAP_PROJ_INIT(Projection [, DATUM=value] [, /GCTP] [, LIMIT=vector] [, /RADIANS] [, /RELAXED] )

Keywords-Projection Parameters:

[, CENTER_AZIMUTH=value] [, CENTER_LATITUDE=value] [, CENTER_LONGITUDE=value] [, FALSE_EASTING=value] [, FALSE_NORTHING=value] [, HEIGHT=value] [, HOM_AZIM_LONGITUDE=value] [, HOM_AZIM_ANGLE=value] [, HOM_LATITUDE1=value] [, HOM_LATITUDE2=value] [, HOM_LONGITUDE1=value] [, HOM_LONGITUDE2=value] [, IS_ZONES=value] [, IS_JUSTIFY=value] [, MERCATOR_SCALE=value] [, OEA_ANGLE=value] [, OEA_SHAPEM=value] [, OEA_SHAPEN=value] [, ROTATION=value] [, SEMIMAJOR_AXIS=value] [, SEMIMINOR_AXIS=value] [, SOM_INCLINATION=value] [, SOM_LONGITUDE=value] [, SOM_PERIOD=value] [, SOM_RATIO=value] [, SOM_FLAG=value] [, SOM_LANDSAT_NUMBER=value] [, SOM_LANDSAT_PATH=value] [, SPHERE_RADIUS=value] [, STANDARD_PARALLEL=value] [, STANDARD_PAR1=value] [, STANDARD_PAR2=value] [, SAT_TILT=value] [, TRUE_SCALE_LATITUDE=value] [, ZONE=value]

Return Value

The result is a !MAP structure containing the map parameters, which can be used as input to the map transformation functions MAP_PROJ_FORWARD and MAP_PROJ_INVERSE.

Arguments

Projection

Set this argument to either a projection index or a scalar string containing the name of the map projection, as described in following tables:

#
Projection Name
Allowed Keyword Parameters
1
Stereographic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
2
Orthographic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
3
Lambert Conic
SPHERE_RADIUS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE
4
Lambert Azimuthal
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
5
Gnomonic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
6
Azimuthal Equidistant
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
7
Satellite
SPHERE_RADIUS, HEIGHT, SAT_TILT, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
8
Cylindrical
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
9
Mercator
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
10
Mollweide
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
11
Sinusoidal
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
12
Aitoff
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
13
Hammer Aitoff
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
14
Albers Equal Area Conic
SPHERE_RADIUS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE
15
Transverse Mercator
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, MERCATOR_SCALE, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
16
Miller Cylindrical
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
17
Robinson
SPHERE_RADIUS, CENTER_AZIMUTH, CENTER_LONGITUDE, CENTER_LATITUDE, ROTATION
18
Lambert Ellipsoid Conic
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE
19
Goodes Homolosine
SPHERE_RADIUS, CENTER_LONGITUDE

The following are GCTP projections:

#
Projection Name
Allowed Keyword Parameters
101
UTM
CENTER_LONGITUDE, CENTER_LATITUDE, ZONE
102
State Plane
ZONE
103
Albers Equal Area
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
104
Lambert Conformal Conic
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
105
Mercator
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, CENTER_LONGITUDE, TRUE_SCALE_LATITUDE, FALSE_EASTING, FALSE_NORTHING
106
Polar Stereographic
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
107
Polyconic
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
108
Equidistant Conic A
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, STANDARD_PARALLEL, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
208
Equidistant Conic B
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, STANDARD_PAR1, STANDARD_PAR2, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
109
Transverse Mercator
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, MERCATOR_SCALE, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
110
Stereographic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
111
Lambert Azimuthal
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
112
Azimuthal
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
113
Gnomonic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
114
Orthographic
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
115
Near Side Perspective
SPHERE_RADIUS, HEIGHT, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
116
Sinusoidal
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
117
Equirectangular
SPHERE_RADIUS, CENTER_LONGITUDE, TRUE_SCALE_LATITUDE, FALSE_EASTING, FALSE_NORTHING
118
Miller Cylindrical
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
119
Van der Grinten
SPHERE_RADIUS, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
120
Hotine Oblique Mercator A
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, MERCATOR_SCALE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING, HOM_LONGITUDE1, HOM_LATITUDE1, HOM_LONGITUDE2, HOM_LATITUDE2
220
Hotine Oblique Mercator B
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, MERCATOR_SCALE, HOM_AZIM_ANGLE, HOM_AZIM_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING
121
Robinson
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
122
Space Oblique Mercator A
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, SOM_INCLINATION, SOM_LONGITUDE, FALSE_EASTING, FALSE_NORTHING, SOM_PERIOD, SOM_RATIO, SOM_FLAG
222
Space Oblique Mercator B
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, SOM_LANDSAT_NUMBER, SOM_LANDSAT_PATH, FALSE_EASTING, FALSE_NORTHING
123
Alaska Conformal
SEMIMAJOR_AXIS, SEMIMINOR_AXIS, FALSE_EASTING, FALSE_NORTHING
124
Interrupted Goode
SPHERE_RADIUS
125
Mollweide
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
126
Interrupted Mollweide
SPHERE_RADIUS
127
Hammer
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
128
Wagner IV
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
129
Wagner VII
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING
130
Oblated Equal Area
SPHERE_RADIUS, OEA_SHAPEM, OEA_SHAPEN, CENTER_LONGITUDE, CENTER_LATITUDE, FALSE_EASTING, FALSE_NORTHING, OEA_ANGLE
131
Integerized Sinusoidal
SPHERE_RADIUS, CENTER_LONGITUDE, FALSE_EASTING, FALSE_NORTHING, IS_ZONES, IS_JUSTIFY

Keywords

Note
The following keywords apply to all projections.

DATUM

Set this keyword to either an integer code or a scalar string containing the name of the datum to use for the ellipsoid. The default value depends upon the projection selected, but is either the Clarke 1866 ellipsoid (datum 0), or a sphere of radius 6370.997 km (datum 19).

The following datums (or spheroids) are available for use with the DATUM keyword:

Index
Name
Semimajor axis (m)
Semiminor axis (m)
0
Clarke 1866
6378206.4
6356583.8
1
Clarke 1880
6378249.145
6356514.86955
2
Bessel
6377397.155
6356078.96284
3
International 1967
6378157.5
6356772.2
4
International 1909
6378388.0
6356911.94613
5
WGS 72
6378135.0
6356750.519915
6
Everest
6377276.3452
6356075.4133
7
WGS 66
6378145.0
6356759.769356
8
GRS 1980/WGS 84
6378137.0
6356752.31414
9
Airy
6377563.396
6356256.91
10
Modified Everest
6377304.063
6356103.039
11
Modified Airy
6377340.189
6356034.448
12
Walbeck
6378137.0
6356752.314245
13
Southeast Asia
6378155.0
6356773.3205
14
Australian National
6378160.0
6356774.719
15
Krassovsky
6378245.0
6356863.0188
16
Hough
6378270.0
6356794.343479
17
Mercury 1960
6378166.0
6356784.283666
18
Modified Mercury 1968
6378150.0
6356768.337303
19
Sphere
6370997.0
6370997.0

Note
For many projections, you can specify your own datum by using either the SEMIMAJOR_AXIS and SEMIMINOR_AXIS or the SPHERE_RADIUS keywords.

GCTP

Set this keyword to indicate that the GCTP library should be used for the projection. By default, MAP_PROJ_INIT uses the IDL projection library. This keyword is ignored if the projection exists only in one system (GCTP or IDL), or if the Projection argument is specified as an index.

LIMIT

Set this keyword to a four-element vector of the form

[Latmin, Lonmin, Latmax, Lonmax]  

that specifies the boundaries of the region to be mapped. (Lonmin, Latmin) and (Lonmax, Latmax) are the longitudes and latitudes of two points diagonal from each other on the region's boundary.

Note
When using MAP_PROJ_FORWARD, if the longitude range in LIMIT is less than or equal to 180 degrees, map clipping is performed in lat/lon coordinates before the transform. If the longitude range is greater than 180 degrees, map clipping is done in Cartesian coordinates after the transform. For non-cylindrical projections, clipping after the transformation to Cartesian coordinates means that some lat/lon points that fall outside the bounds specified by LIMIT may not be clipped. This occurs when the transformed lat/lon points fall inside the cartesian clipping rectangle.

RADIANS

Set this keyword to indicate that all parameters that represent angles are specified in radians rather than degrees.

RELAXED

If this keyword is set, any projection parameters which do not apply to the specified projection will be quietly ignored. By default, MAP_PROJ_INIT will issue errors for parameters that do not apply to the specified projection.

Projection Keywords

The following keywords apply only to some projections. Consult the list under Projection to determine which keywords apply to the projection you have selected.

Note
Unless the RADIANS keyword is set, all angles are measured in degrees, specified as a floating-point value.

CENTER_AZIMUTH

Set this keyword to the angle of the central azimuth, in degrees east of North. The default is 0 degrees. The pole is placed at an azimuth of CENTRAL_AZIMUTH degrees counterclockwise of North, as specified by the ROTATION keyword.

CENTER_LATITUDE

Set this keyword to the latitude of the point on the earth's surface to be mapped to the center of the projection plane. Latitude is measured in degrees North of the equator and must be in the range: -90 to +90. The default value is zero.

CENTER_LONGITUDE

Set this keyword to the longitude of the point on the earth's surface to be mapped to the center of the map projection. Longitude is measured in degrees east of the Greenwich meridian and must be in the range: -360 to +360. The default value is zero.

FALSE_EASTING

Set this keyword to the false easting value (in meters) to be added to each x coordinate for the forward transform, or subtracted from each x coordinate for the inverse transform.

FALSE_NORTHING

Set this keyword to the false northing value (in meters) to be added to each y coordinate for the forward transform, or subtracted from each y coordinate for the inverse transform.

HEIGHT

Set this keyword to the height (in meters) above the earth's surface for satellite projections.

HOM_AZIM_LONGITUDE

Set this keyword to the longitude in degrees of the central meridian point where the azimuth occurs.

HOM_AZIM_ANGLE

Set this keyword to the azimuth angle, measured in degrees, east of a north-south line that intersects the center line. The center line is defined as the great circle path along which the Mercator cylinder touches the sphere.

HOM_LATITUDE1

Set this keyword to the latitude in degrees of the first point on the center line. The center line is defined as the great circle path along which the Mercator cylinder touches the sphere.

HOM_LATITUDE2

Set this keyword to the latitude in degrees of the second point on the center line. The center line is defined as the great circle path along which the Mercator cylinder touches the sphere.

HOM_LONGITUDE1

Set this keyword to the longitude in degrees of the first point on the center line. The center line is defined as the great circle path along which the Mercator cylinder touches the sphere.

HOM_LONGITUDE2

Set this keyword to the longitude in degrees of the second point on the center line. The center line is defined as the great circle path along which the Mercator cylinder touches the sphere.

IS_ZONES

Set this keyword to the number of longitudinal zones to include in the projection.

IS_JUSTIFY

Set this keyword to a flag indicating what to do with rows with an odd number of columns. The possible values are:

Value
Description
0
Indicates the extra column is on the right of the projection Y axis.
1
Indicates the extra column is on the left of the projection Y axis.
2
Calculate an even number of columns.

MERCATOR_SCALE

Set this keyword to the scale factor at the central meridian (Transverse Mercator projection) or the center of the projection (Hotine Oblique Mercator projection). For the Transverse Mercator projection, the default scale is 0.9996.

OEA_ANGLE

Set this keyword to the Oblated Equal Area oval rotation angle in degrees.

OEA_SHAPEM

Set this keyword to the Oblated Equal Area shape parameter m. The value of OEA_SHAPEM determines the horizontal flatness of the oblong region, and is usually set to a value between one and three.

OEA_SHAPEN

Set this keyword to the Oblated Equal Area oval shape parameter n. The value of OEA_SHAPEN determines the vertical flatness of the oblong region, and is usually set to a value between one and three.

Note
Setting both OEA_SHAPEM and OEA_SHAPEN equal to two is equivalent to using the Lambert Azimuthal projection.

ROTATION

Set this keyword to the angle through which the North direction should be rotated around the line between the earth's center and the point (CENTER_LONGITUDE, CENTER_LATITUDE). ROTATION is measured in degrees with the positive direction being clockwise rotation around the line. Values should be in the range -180 to +180. The default value is zero.

Note
If the center of the map is at the North pole, North is in the direction CENTER_LONGITUDE + 180. If the origin is at the South pole, North is in the direction CENTER_LONGITUDE.

SEMIMAJOR_AXIS

Set this keyword to the length (in meters) of the semimajor axis of the reference ellipsoid. The default is either the Clarke 1866 datum (6378206.4 m) or the Sphere radius (6370997 m), depending upon the projection.

SEMIMINOR_AXIS

Set this keyword to the length (in meters) of the semiminor axis of the reference ellipsoid. The default is either the Clarke 1866 datum (6356583.8 m) or the Sphere radius (6370997 m), depending upon the projection.

SOM_INCLINATION

Set this keyword to the orbit inclination angle in degrees of the ascending node, counter-clockwise from equator.

SOM_LONGITUDE

Set this keyword to the longitude in degrees of the ascending orbit at the equator.

SOM_PERIOD

Set this keyword to the period in minutes of the satellite revolution.

SOM_RATIO

Set this keyword to the Landsat ratio to compensate for confusion at the northern end of orbit. A typical value is 0.5201613.

SOM_FLAG

Set this keyword to the end of path flag for Landsat, where 0 is the start and 1 is the end.

SOM_LANDSAT_NUMBER

Set this keyword to the Landsat satellite number.

SOM_LANDSAT_PATH

Set this keyword to the Landsat path number (use 1 for Landsat 1, 2 and 3; use 2 for Landsat 4, 5 and 6).

SPHERE_RADIUS

Set this keyword to the radius (in meters) of the reference sphere. The default is 6370997 m.

STANDARD_PARALLEL

Set this keyword to the latitude in degrees of the standard parallel along which the scale is true.

STANDARD_PAR1

Set this keyword to the latitude in degrees of the first standard parallel along which the scale is true.

STANDARD_PAR2

Set this keyword to the latitude in degrees of the second standard parallel along which the scale is true.

SAT_TILT

Set this keyword to the downward tilt in degrees of the camera, in degrees from the projection horizontal.

TRUE_SCALE_LATITUDE

Set this keyword to the latitude in degrees of true scale.

ZONE

Set this keyword to an integer giving the zone for the GCTP UTM projection or GCTP State Plane projection.

Note
For the UTM projection, you may also use the CENTER_LONGITUDE and CENTER_LATITUDE keywords to set the zone. Internally, the ZONE value will be computed from the longitude and latitude.

Example

See MAP_PROJ_FORWARD for an example of using this function.

Version History

Introduced: 5.6

See Also

MAP_PROJ_FORWARD, MAP_PROJ_INVERSE, MAP_SET


Home | Categories | Alphabetical | Classes | All Contents | [ < ] | [ > ]