GIScience / openrouteservice

🌍 The open source route planner api with plenty of features.
https://openrouteservice.org
GNU General Public License v3.0
1.43k stars 390 forks source link

Isochrone intersections lack documentation and api-tests #879

Open koebi opened 3 years ago

koebi commented 3 years ago

Here's what I did

I tried to write an API-Test for Isochrone requests with intersections:true in body. To do s, I wanted to figure out how isochrone intersections work and what will be returned, as to be able to check for correct returns.


Here's where I got

nothing - isochrone intersections aren't documented. In fact, Isochrone responses aren't documented at all, as far as I could tell.


Here's what I was expecting

Some documentation


Here's what I think could be improved

Isochrone documentation :)

koebi commented 1 year ago

Isochrone requests with intersections=true return a GeoJSON that one can think of consisting of two parts:

The isochrones similar to a regular isochrone request.

Each isochrone returned has a group_index-property and a value-property. The group_index-property is equal to the index of the point in the locations-array in the query. The value property corresponds to the range given in the query. If you consider the values as an array, you can assign an index to each value that will be needed below.

The intersections of the above isochrones.

Each isochrone here has a contour-property. This property has the form [[A,x],[B,y]], and will be the intersection of the two isochrones with group_index A, value-"index" x and group_index B, value-"index" y.

The following images may serve to illustrate this:

d c b a