logo separator

[mkgmap-dev] Sea tiles problem

From Christian Gawron christian.gawron at googlemail.com on Mon Oct 26 12:14:26 GMT 2009

Toby Speight schrieb:
> I've just started using the --generate-sea option, and it almost works.
> The problem is that of the UK, the whole of northern Scotland (north of
> a line through Stirling) is inverted - i.e. the land is blue and the sea
> is light yellow (black at night).  This is inconvenient, as that's where
> I live.
> What's the likely cause?  Could it be due to an island that's tagged in
> the wrong direction?  I've checked the most northerly and most westerly
> islands and they all look okay to me.  GeoFabrik's OSM Inspector doesn't
> flag up any coastline errors in that area, so that's no help.
Could you provide me a download link for the offending tile?
Did mkgmap print a warning message "Non-closed coastline segment does 
not hit bounding box: ..."?

The algorithm I implemented handles two cases of land masses:
- closed shoreline segments (aka islands)
- shoreline segments which are not closed but extend to the border of 
the tile (i.e. the intersection of a closed shoreline with the bounding box)

In the latter case the shoreline is "closed" along the tile border.
The algorithm then generates a sea background and a multipolygon 
relation which adds a "hole" for each landmass.
Obviously a landmass with a non-closed boundary will be drowned by that 
approach :-)

One limitation I know of arises with country extracts from geofabrik - 
they have shorelines cut-off at the country border. As UK is a big 
island, this should not be the cause of your problem, though.

Best wishes

More information about the mkgmap-dev mailing list