Coastline

From OpenStreetMap Wiki
Jump to: navigation, search
Help
Available languages
Deutsch English
logo Coastline
One example for Coastline
Description
Where the land meets the sea
Tags
natural=coastline

Mapping the coastline, where the sea meets the land.

Contents

Coastal features

Caution should be taken when editing the coastline. The coastline ideally needs to be an unbroken chain of ways around entire continents (for example an unbroken chain of ways around Americas (north and south) and a break in the coastline can cause difficulties for renderers. If you are not confident about editing then it is best to not make major changes beyond adjusting nodes to align better with aerial imagery.

The sea is delineated using natural=coastline with the direction of coastline organised so that land is always on the left of the way in the direction it is drawn. Islands in the sea are similarly delineated. Islands in lakes and rivers are tagged differently except for the Great Lakes in North America which are tagged using the coastline method due to their size.

Where a wide river defined using waterway=riverbank flows into the sea it will be necessary to determine where to make the 'join' between the sea and river. This need not be at the highest point of the tide and is generally a matter of personal judgement and style. The coastline maintains its integrity across the 'join' as does the area forming the riverbank. Where the sea joins a narrow river represented by a linear waterway=river is should terminate on a node on the coastline.

Along the coast it is often useful to add natural=beach and natural=cliff for beaches and cliffs; also natural=wetland for various forms of wetland, including wetland=tidalflat, wetland=mangrove etc. man_made=groyne can be used for sea defenses.


Rendering

Tiles at Home

The process for generating coastline rendering is described more fully at Tiles@home/Dev/Interim_Coastline_Support. Essentially however it allows data to be brought into the main OSM database and tagged as Tag:natural=coastline, which will cause detailed coastline to be rendered.

Since the detailed data is in the main database it can be edited in any of the usual tools, Potlatch or JOSM, which allows for correction of inaccuracies, particularly where the area in question is covered by Yahoo imagery, and the coastline can be moved to fit the image. On a larger scale the Coastline error checker gives, worldwide, a daily view of where the coastlines have been uploaded and where there are problems.

Main Mapnik layer

At low zoom levels, up to and including zoom level 9, Mapnik renders all the sea as a solid fill of blue, generated from the shapefile shoreline_300 (used for z0-9), which has a relatively low resolution. At high zoom levels the coast polygons used are generated from the natural=coastline tag -- the data is made available to the Mapnik renderer as a large shapefile (processed_p) which is generated every few weeks from planet dumps (note: if you edit coastline at high zooms, be patient for it to render).

Other users of Mapnik may handle coastline differently.

Shapefiles from the database

The main problem of showing coastlines from OSM data is that Mapnik really needs closed polygons. The polygon can (and normally should) be made of several ways, but the ways should join end-to-end and eventually loop back round without interruption, to close the polygon. An imperfect coastline with many small gaps, reversed ways and other defects will cause the polygon to break, and the coastline to be rendered incorrectly . One of the features of the Coastline error checker is to try and join coastlines in such a way as to make high-quality coastlines even with these imperfections. As the coastlines are uploaded and completed the quality can be checked.

Coastline integrity

In the database we can create coastline ways with Tag:natural=coastline, however if/how this is rendered, is a complicated matter… For more details see de:Coastline and de:boundary sea sided (please translate it to here). Unlike many things you see on the maps the rendering of coastline is handled significantly differently in the The Tiles@home ('osmarender' layer) and the Mapnik layer.

Uploading coastline

If the part of the world you are interested in does not appear to have its coastline in the database, then look at Running the coastline upload to find out how to upload it yourself.

Coastline checker

Coastline error checker

Personal tools
Namespaces
Variants
Actions
site
Toolbox