E
E
Express7772015-11-05 08:09:37
OpenStreetMap
Express777, 2015-11-05 08:09:37

How to get the coordinates of the administrative districts of the city in Open street Map?

Hello.
You need to show the administrative districts of the city on the Yandex map. Already contacted Yandex technical support. Their answer is "this cannot be done using the Yandex Maps API."
There is another way. Draw a polygon on the map. But you need to know the coordinates of the polygon boundaries. For example in the form of an array.

[43.238536, 76.809829],
                    [43.229531, 76.814636],
                    [43.225028, 76.821674],
                    [43.214770, 76.827854],
                    [43.209641, 76.833519],

и т.д.

Google suggests that these coordinates can be taken from the Open Street Map.
That's just how to do it?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
P
pfg21, 2015-11-11
@pfg21

Openstreetmap has a great overpass-turbo tool that allows you to search objects with specific tags in boundarybox.
For city districts, this will be boundary=administrative adminlevel=*
See wiki.openstreetmap.org/wiki/RU:Tag:boundary%3Dadministrative for the adminlevel
level
. containing points with the desired coordinates. Filter out unnecessary areas by name tag

D
Dmitry, 2015-11-05
@e-developer

You need to take an OSM dump (for example, here , but there are a lot of them, look for "osm dump") and see if there are district boundaries there.

F
freeExec, 2015-11-13
@freeExec

Considering that you chose Y.K., then apparently everything is bad in OSM. So the boundaries of the regions in that territory are clearly absent.
And so, yes, overpass can give data immediately in a convenient geojson, which can be immediately shown.

E
Express777, 2015-11-13
@Express777

There is also an answer on Stackoverflow
ru.stackoverflow.com/questions/462506/%D0%9A%D0%B0...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question