Inclination as custom routing parameter

28 views
Skip to first unread message

Lorenzo Stucchi

unread,
Sep 1, 2020, 9:35:32 AM9/1/20
to 'e.ru...@quicknet.nl' via OsmAnd
Hi all,

I’m creating a custom routing profile and I would like to consider the tag “incline” that assume a positive or a negative value (15% or -15%), I created a parameter “max_incline” that should not consider the streets that have an inclination lower than the negative value of “max_incline” or over the value of “max_incline”. In others programming code I will use the absolute value to consider the positive and the negative values. It is possible to have a similar approach?

For now I was able to solve the issue asking to the user to select the “max_incline” value twice, one time assigning a negative value and the second time a positive value and after to insert this:

<way attribute="access”>
<gt value1=":incline_max_neg" value2="$incline”>
<select value="-1" t="incline”/>
</gt>
<gt value1="$incline" value2=":incline_max”>
<select value="-1" t="incline”/>
</gt>
</way>

Thanks for your attention.

Best,
Lorenzo Stucchi
Reply all
Reply to author
Forward
0 new messages