1PnmMercator User Manual(0)                          PnmMercator User Manual(0)
2
3
4
5<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
6
7
8<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
9

NAME

11       pnmmercator  - transform a worldmap from rectangular projection to Mer‐
12       cator projection and vice-versa
13
14

SYNOPSIS

16       pnmmercator [-inverse] [-nomix] [-[v]verbose] [filename]
17
18       Minimum unique abbreviation of option is acceptable.  You may use  dou‐
19       ble hyphens instead of single hyphen to denote options.
20
21

DESCRIPTION

23       This program is part of Netpbm(1).
24
25       The  pnmmercator utility, converts a rectangular projection worldmap to
26       a Mercator projection format, as  used  for  maps.google.com  and  many
27       other  online  maps.   The  map used as input for pnmmercator must have
28       rows for -90 to 90 degrees  latitude  and  columns  for  -180  to  +180
29       degrees  longitude.  The  file will typically be twice as wide as high,
30       but this is not a requirement.  The  output  file  will  be  using  the
31       Mercator projection ⟨http://en.wikipedia.org/wiki/Mercator_projection
32       and will get double the height of the input file.
33
34       Maps using the Mercator projection are stretched more the closer a  row
35       is  to  the  North  or  South Pole. The last few degrees (> 85 or < -85
36       degrees) are not part of a Mercator map at all because  they  would  be
37       stretched  too  much  and the rows close to the edge will show banding,
38       because they originate from the same row in the original map.
39
40       To overcome this, the program will by default do interpolation of pixel
41       colors,  which  will  eliminate the banding effect, but will cause some
42       blurring of the output. With the -nomix option, this  interpolation  of
43       colors  isn't  applied.  You  can  obtain the highest quality output by
44       starting with an input map of high resolution, so that you  can  follow
45       the pnmmercator transformation with a pamscale reduction in size.
46
47       This  program can also convert a Mercator projection map back to a rec‐
48       tangular projection based.  As said,  the  Mercator  map  doesn't  have
49       information  about the latitudes close to the poles.  Therefore the top
50       rows in the output image will be identical and copied from the row cor‐
51       responding  with  latitude of 85 degrees. The same at the bottom of the
52       map.
53
54       Pnmmercator doesn't have any provision for scaling the image.  You  can
55       scale  by piping the output of the program through Netpbm programs such
56       as pamscale.
57
58       You can find maps to be used as input at  flatplanet.sourceforge.net(1)
59       or uic.edu/pape ⟨http://www.evl.uic.edu/pape/data/Earth/⟩ .
60
61       The  point of a Mercator projection map is that compass directions work
62       on it.  If you draw a straight line northeast from some  point  on  the
63       Mercator map, the line traces the course you would sail if you sailed a
64       compass bearing of northeast from that spot.  Naturally, primitive nav‐
65       igators  appreciated  that.   The  biggest drawback of Mercator is that
66       areas to the north and south appear much larger than they are  in  real
67       life.   For  example, Greenland appears to be larger than South America
68       even though it only a ninth as large.  Note that areas  away  from  the
69       equator are stretched north-south as well as east-west.
70
71       A rectangular projection is one where vertical distance is proportional
72       to angular latitude distance of the  represented  area  and  horizontal
73       distance is proportional to angular longitude.
74
75
76

PARAMETERS

78       filename  is  the  name  of the input file.  If you don't specify this,
79       pnmmercator reads the image from standard Input.
80
81

OPTIONS

83       <dl compact="compact">
84
85       -inverse
86
87              With this option  a  conversion  from  Mercator  to  degrees  is
88              applied.The  output image will have half the height of the input
89              map.
90
91
92       -nomix
93
94              Default behaviour is that color blending is applied  in  between
95              two  adjacent rows. If you specify the -nomix parameter there is
96              no blending. The consequence is a banding at the top and  bottom
97              of  the map.  With this option, the output map will also consist
98              of exactly the same colors as the input.
99
100
101       -verbose and -vverbose
102
103              This parameter outputs some additional information. If you  dou‐
104              ble the 'v', it will output debug data about the lat/long degree
105              and Mercator conversions.
106
107
108
109

SEE ALSO

111       pnm(1)and pamscale(1) ppmglobe(1)
112
113

HISTORY

115       pnmmercator was new in Netpbm 10.49 (December 2009).
116
117

AUTHORS

119       Willem van Schaik (of pnmtopng/pngtopnm fame)  wrote  this  program  in
120       October 2009 and suggested it for inclusion in Netpbm.
121
122
123
124netpbm documentation             October 2009       PnmMercator User Manual(0)
Impressum