Debian Codegraph @

upstream/debian-unstable/man1/pnmmercator.1

raw
1 \
2 .\" This man page was generated by the Netpbm tool 'makeman' from HTML source.
3 .\" Do not hand-hack it! If you have bug fixes or improvements, please find
4 .\" the corresponding HTML page on the Netpbm website, generate a patch
5 .\" against that, and send it to the Netpbm maintainer.
6 .TH "PnmMercator User Manual" 1 "October 2009" "netpbm documentation"
7
8 .SH NAME
9 pnmmercator - transform a worldmap from rectangular projection to Mercator
10 projection and vice-versa
11
12 .UN synopsis
13 .SH SYNOPSIS
14 \fBpnmmercator\fP
15 [\fB-inverse\fP]
16 [\fB-nomix\fP]
17 [\fB-[v]verbose\fP]
18 [\fB\fIfilename\fP\fP]
19 .PP
20 Minimum unique abbreviation of option is acceptable.
21 You may use double hyphens instead of single hyphen to denote options.
22
23 .UN description
24 .SH DESCRIPTION
25 .PP
26 This program is part of
27 .BR "Netpbm" (1)\c
28 \&.
29 .PP
30 The \fBpnmmercator\fP utility, converts a rectangular projection worldmap
31 to a Mercator projection format, as used for maps.google.com and many other
32 online maps. The map used as input for \fBpnmmercator\fP must have rows for
33 -90 to 90 degrees latitude and columns for -180 to +180 degrees longitude. The
34 file will typically be twice as wide as high, but this is not a
35 requirement. The output file will be using the
36 .UR http://en.wikipedia.org/wiki/Mercator_projection
37 Mercator projection
38 .UE
39 \& and will get double the height of the input file.
40 .PP
41 Maps using the Mercator projection are stretched more the closer a row is
42 to the North or South Pole. The last few degrees (> 85 or < -85 degrees)
43 are not part of a Mercator map at all because they would be stretched too much
44 and the rows close to the edge will show banding, because they originate from
45 the same row in the original map.
46 .PP
47 To overcome this, the program will by default do interpolation of pixel
48 colors, which will eliminate the banding effect, but will cause some blurring
49 of the output. With the -nomix option, this interpolation of colors isn't
50 applied. You can obtain the highest quality output by starting with an input
51 map of high resolution, so that you can follow the \fBpnmmercator\fP
52 transformation with a \fBpamscale\fP reduction in size.
53 .PP
54 This program can also convert a Mercator projection map back to a
55 rectangular projection based. As said, the Mercator map doesn't have
56 information about the latitudes close to the poles. Therefore the top rows in
57 the output image will be identical and copied from the row corresponding with
58 latitude of 85 degrees. The same at the bottom of the map.
59 .PP
60 Pnmmercator doesn't have any provision for scaling the image. You can scale
61 by piping the output of the program through Netpbm programs such as
62 \fBpamscale\fP.
63 .PP
64 You can find maps to be used as input at
65 .BR "flatplanet.sourceforge.net" (1)\c
66 \&
67 or
68 .UR http://www.evl.uic.edu/pape/data/Earth/
69 uic.edu/pape
70 .UE
71 \&.
72 .PP
73 The point of a Mercator projection map is that compass directions work on
74 it. If you draw a straight line northeast from some point on the Mercator
75 map, the line traces the course you would sail if you sailed a compass bearing
76 of northeast from that spot. Naturally, primitive navigators appreciated
77 that. The biggest drawback of Mercator is that areas to the north and south
78 appear much larger than they are in real life. For example, Greenland appears
79 to be larger than South America even though it only a ninth as large. Note
80 that areas away from the equator are stretched north-south as well as
81 east-west.
82 .PP
83 A rectangular projection is one where vertical distance is proportional to
84 angular latitude distance of the represented area and horizontal distance is
85 proportional to angular longitude.
86
87
88 .UN parameters
89 .SH PARAMETERS
90 .PP
91 \fB\fIfilename\fP\fP is the name of the input file. If you don't specify
92 this, \fBpnmmercator\fP reads the image from standard Input.
93
94 .UN options
95 .SH OPTIONS
96 .PP
97 In addition to the options common to all programs based on libnetpbm
98 (most notably \fB-quiet\fP, see
99 .UR index.html#commonoptions
100 Common Options
101 .UE
102 \&), \fBpnmmercator\fP recognizes the following
103 command line options:
104
105
106 .TP
107 \fB-inverse\fP
108 .sp
109 With this option a conversion from Mercator to degrees is applied.The
110 output image will have half the height of the input map.
111
112 .TP
113 \fB-nomix\fP
114 .sp
115 Default behaviour is that color blending is applied in between two adjacent
116 rows. If you specify the -nomix parameter there is no blending. The
117 consequence is a banding at the top and bottom of the map. With this option,
118 the output map will also consist of exactly the same colors as the input.
119
120 .TP
121 \fB-verbose\fP and \fB-vverbose\fP
122 .sp
123 This parameter outputs some additional information. If you double the 'v',
124 it will output debug data about the lat/long degree and Mercator
125 conversions.
126
127
128
129 .UN seealso
130 .SH SEE ALSO
131 .BR "pnm" (1)\c
132 \& and
133 .BR "pamscale" (1)\c
134 \&
135 .BR "ppmglobe" (1)\c
136 \&
137
138 .UN history
139 .SH HISTORY
140 .PP
141 \fBpnmmercator\fP was new in Netpbm 10.49 (December 2009).
142
143 .UN authors
144 .SH AUTHORS
145 .PP
146 \fIWillem van Schaik\fP (of
147 \fBpnmtopng\fP/\fBpngtopnm\fP fame) wrote this program in October 2009 and
148 suggested it for inclusion in Netpbm.
149 .SH DOCUMENT SOURCE
150 This manual page was generated by the Netpbm tool 'makeman' from HTML
151 source. The master documentation is at
152 .IP
153 .B http://netpbm.sourceforge.net/doc/pnmmercator.html
154 .PP