Thread: [WIP] The SH5 EcoMod
View Single Post
Old 02-01-19, 06:45 AM   #125
OldCoder
Soundman
 
Join Date: Mar 2016
Posts: 142
Downloads: 24
Uploads: 0
Default

Jeff, this may be your answer:

https://github.com/Jorl17/open-eleva...er/docs/api.md

It's a public/free API for elevation queries. Examples are there to call it from curl, but obviously you could easily make a Python script/whatever to send queries.

For instance, in a web browser:

https://api.open-elevation.com/api/v...23826,1.317397

Response:
{"results": [{"latitude": 51.138584, "elevation": 105, "longitude": 1.366985}, {"latitude": 51.123826, "elevation": 7, "longitude": 1.317397}]}

The first set of coordinates are the cliffs to the eastern side of Dover port, returning a height of 105 metres.

The second set of coordinates are also Dover near the sands/seafront shopping area, returning 7m.

The API does respond quite slowly unfortunately (at least for me), so that might be a limiting factor.
OldCoder is offline   Reply With Quote