Replies: 3 comments 5 replies
-
Yeah, it's logical to me what you're describing, but I'd personally refrain from making the (already very complex) API more complex, to accommodate for this. As you mention a workaround exists for a client. |
Beta Was this translation helpful? Give feedback.
-
it might not be all that complicated and it is a pretty useful feature. we would just need another parameter an alternative design would be to keep the single parameter but allow more complicated values like:
so that the parser has to first split on
would be equivalent to:
at any rate, seems like a well scoped, easy to implement feature if you want to take a crack @Trietes |
Beta Was this translation helpful? Give feedback.
-
So now we have two opinions here :D I can understand the argument with making the API more complex. On the other hand I like Valhalla because of exactly this powerfull and complex API. Most other routing engines might have a simpler API, but are far less configurable. In my opinion it would break down to if it is a usefull feature which other people also would like to use. I've I'm the only one who thinks it is a good thing to have and nobody else would use it, its not worth implementing. Regarding the implementation I agree to @kevinkreiser. I already checked the code which handlese the preferred side and it should be pretty straight forward to a new configuration to it. |
Beta Was this translation helpful? Give feedback.
-
Currently the preferred_sie parameter has the options
same
,opposite
andeither
to specifiy the preferred side of the street to route to. In reality the preferred side also depends on the road(-class). For higher road classes the side for e.g. a delivery driver becomes more important, since he doesn't want to cross the street by foot. On the other hand e.g. a residential road can be crossed by foot more easily, so the side of the street doesn't matter that much.I'm currently realising this behaviour by having a /locate request first to determine for each location if arriving on the same side of the street is important, dependent on the road class. Would it be intersting for you guys to have another configuration parameter for the preferred_side option (maybe something like
automatic
orroad_specific
)? Or is this too specific for certain use-cases? Of course the threshold for which road classes the preferred side does matter is debatable.Beta Was this translation helpful? Give feedback.
All reactions