3

Based on my question at StackOverflow https://stackoverflow.com/questions/44021365/openstreetmap-nominatim-and-landuse

Can you tell me if it is possible to get the landuse of a point with latitude/longitude? After my question at StackOverflow, my solution is so far:

http://overpass-api.de/api/interpreter?data=way(around:25,48.7749365,9.1827252)[landuse];(._;>;);out;

If it is not possible to get the landuse from a point, what is the minimum parameter (now 25 meters) that will work? With 20 meters there is a result, too. But is this suitable for most points on islands?

By the way, the query url is generated at runtime.

3
  • There is an experimental version that uses 'way' to find landuse using the a modified (ie self hosted overpass api) see screenshots at the bottom of github.com/drolbr/Overpass-API/issues/77
    – Mapperz
    May 17 '17 at 13:51
  • @Mapperz: unfortunately, this experimental version is not at all supported at this time, so not an option for the OP.
    – mmd
    May 17 '17 at 15:48
  • The use of way is only how far I came. If there are other ways than way, I would use it.
    – muffi
    May 18 '17 at 4:41
3

Technically speaking it is possible via the is_in; statement, although it would require that you set up your own Overpass API instance, and modify the area creation script, so that is also creates areas for landuses without a name.

The area creation script deployed on overpass-api.de requires multipolygon relations and landuse ways to also carry a name tag. In many cases OSM data won't have a name tag.

The solution you've shown above obviously won't work, if you're more than 25 meters away from the way boundary. There's also no generally suitable value which would work under every condition, so around is clearly only of limited use for your use case.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.