mapnik-org/mapnik — Issue #400: Some points from PointDatasource get lost on reprojection
Author: artemp
Created: 2011-10-11 07:53:26+00:00
State: open
Labels: Core_Library

See attached python script to reproduce. Basically, I create a PointDatasource, add several points with longitude/latitude coordinates to it and attach it to a layer with appropriate projection setting ('+proj=latlon +datum=WGS84'). Then I try to render a map with this layer. Depending on the map projection setting, one or more points get lost.

In an ordinary mercator projection ('+proj=merc +datum=WGS84 +k=1.0 +units=m +over +no_defs'), reproducibly the southernmost point vanishes. In fact, I can work around the problem by setting an invisible 'dummy' point south of the area of interest.

In UTM, additionally the westernmost point disappears.

On the other hand, a map in "Google" spherical mercator projection displays all points. So does a simple latlon map where no reprojection is necessary.

Reading the same points from a shapefile works for all these output projections.