3 This document describes the format of the .mapinfo configuration file,
4 which specifies the maps (and their projection parameters) available to
8 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
11 The .mapinfo file has a simple line-oriented syntax. Each line
12 independently specifies some piece of information, and the order of the
13 lines is unimportant. Blank lines and lines starting with '#', which
14 may be preceded by whitespace, are ignored. All other lines must have
15 the syntax described below.
17 We use a few conventions in the following description of the syntax.
18 Placeholders are denoted by words enclosed in angle brackets (e.g.,
19 <map-name>). All other words are literals that should be included
20 verbatim. The order of the words on each line is significant. One or
21 more whitespace characters should separate the individual words on each line.
25 MAP <map-name> <image-path> <top-lat> <top-long> <bot-lat> <bot-long>
27 MAP World World100.png 90 -170 -90 190
29 These lines specify a map that is available to the user and supply some
34 <map-name> -- the name of the map; this is the name used for the '-m'
35 command line argument; the name must consist of letters,
36 digits, and underscores--no spaces are allowed
38 <image-path> -- the name of the PNG file containing the map image; the
39 path is relative to the location of the .mapimages directory,
40 so in most cases, the path can be a simple filename such as
44 <top-long> -- the lat/long of the top-left corner of the map image in
48 <bot-long> -- the lat/long of the bottom-right corner of the map image in
52 2) map projection parameters:
54 PROJECTION <map-name> <projection-name> <projection parameters>
56 PROJECTION USA50 ALBER 704.0 30.8 45.5 21.86 -99.9 232 388
58 These lines specify the parameters for nonlinear map projections. In
59 contrast, the values given in MAP lines are sufficient for linear map
64 <map-name> -- the name of the map; this value should match the name used
65 in the corresponding MAP line
67 <projection-name> -- the name of the nonlinear projection that will be
68 applied to the map; currently, if maps are not linear, they may
69 have one nonlinear projection specified for them; multiple
70 nonlinear projections for the same map are not allowed
72 <projection parameters> -- a variable set of values that provides the
73 actual parameters for the map projection; see below for details
76 The following describes the supported projections and their parameters.
77 Only one projection is currently supported:
79 ALBER -- an Alber/Lambert projection; this is used by the USA maps
80 included in the distribution
82 See the publication "Map Projections Used by the U.S. Geological
83 Survey Bulletin 1532" for details about this projection.
87 <R> <phi_1> <phi_2> <phi_0> <lambda_0> <false-easting> <false-northing>
91 <R> -- radius of sphere
92 <phi_1> -- standard parallel (lower)
93 <phi_2> -- standard parallel (upper)
94 <phi_0> -- origin latitude
95 <lambda_0> -- origin longitude
96 <false-easting> -- the false easting amount
97 <false-northing> -- the false northing amount
100 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
103 Creating maps at different scales is both useful and relatively easy.
104 The following describes the steps for creating maps at different scales
107 1) Use an image editing tool/package like ImageMagick or NetPBM to create
108 a map image at a different size; e.g.,
110 convert -scale '50%' .mapimages/World100.png .mapimages/World50.png
112 would create a half-sized image using the 'convert' tool of ImageMagick.
114 2) Add a MAP line to .mapinfo; specifically, copy the MAP line of the
115 source map and change the map name and image path--don't change the
116 lat/long parameters; e.g.,
118 MAP World100 World100.png 90 -170 -90 190
119 => MAP World50 World50.png 90 -170 -90 190
121 3) For maps created with nonlinear projections, add a PROJECTION line to
122 .mapinfo; again, you may simply copy and tweak the PROJECTION line of
123 the source map; e.g.,
125 PROJECTION USA50 ALBER 704.0 30.8 45.5 21.86 -99.9 232 388
126 PROJECTION USA100 ALBER 1408.0 30.8 45.5 21.86 -99.9 464 776
127 PROJECTION USA200 ALBER 2816.0 30.8 45.5 21.86 -99.9 928 1552
129 For the Alber/Lambert projection, you need only change the <R>,
130 <false-easting>, and <false-northing> parameters. These values change
131 in direct proportion to the change in size of the image itself. For
132 example, if the size is halved, then these parameter values should be
133 halved; if the size is doubled, then the values should be doubled.
134 In the above example, USA100 is the USA map at 100%; USA50 and USA200
135 represent images at 50% and 200%, respectively.