Answer the question
In order to leave comments, you need to log in
Maps API, how to get the coordinates and size of an object?
For a home project, you need to get the coordinates of nearby buildings and their sizes. Accuracy is not important.
There are folk cards on Yandex . When hovering, polygons are highlighted. Ideally, I would like to get these polygons in the N radius from the point.
It doesn't matter which map service you use.
Please poke your nose into the service / API. If this is not possible through the API, then you can discuss what other options are.
There is only one thought in my head. We raise the node, start the puppeteer (headless chrome), make screenshots, parse screenshots through some kind of openCV or similar libs.
Answer the question
In order to leave comments, you need to log in
It is possible through the API and in a bunch of ways to do this.
For example, you can make a request via the overpass-turbo.eu API to OSM data and pull out certain types of objects within a certain radius. The sizes of objects are then calculated based on their coordinates, for example using the GDAL library .
You can import OSM data from your neighborhood into postgres, for example with osm2pgsql .
The postgis extension allows you to do almost any calculation with geo-objects. For example, you can take an enclosing rectangle and convert its projection to meters. The difference in the coordinates of the corners will be the size of the circumscribed rectangle.
The Internet is full of articles on how to work with geo-data in postgis. Try, ask specific questions, we will answer.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question