[OSM-dev] determining the boundaries of cities?

Ákos Maróy akos at maroy.hu
Wed May 30 21:20:43 BST 2012


Hi,

I wonder what is the best way to determine city boundaries based on the
OSM dataset. What I want to do is simply to have each city colored in
light yellow (uniformly), with a black outline at the edge of each city.
I'm not concerned about the streets inside the cities, etc.

I looked at the OSM data for Hungary, and of course at the OSM Wiki, but
I'm still yet to be able to determine the best way to achieve the above.

One possibility seemed to be to go with:

boundary = administrative && admin_level = 8


but this will actually create a full tiling of the map - the edges of
these areas not the edges of the cities themselves, but they 'fill up
the space' up to the neighboring such areas. basically the 'rural area'
between the cities is filled up


another approach I tried is going for the landuse property, and consider
areas with the following values 'cities':

residential
industrial
commercial
park
parking
...


but this data seems to be inconclusive. for example, most of the area of
the city of Budapest is not marked with landuse areas.


am I missing something obvious, or is is it the case that the boundaries
of cities is simply not stored in the OSM dataset?


Akos



More information about the dev mailing list