diff --git a/brouter-routing-app/assets/profiles2.zip b/brouter-routing-app/assets/profiles2.zip index 7291edd..57d419d 100644 Binary files a/brouter-routing-app/assets/profiles2.zip and b/brouter-routing-app/assets/profiles2.zip differ diff --git a/misc/profiles2/shortest.brf b/misc/profiles2/shortest.brf index 0345585..ee1eacb 100644 --- a/misc/profiles2/shortest.brf +++ b/misc/profiles2/shortest.brf @@ -7,6 +7,7 @@ assign downhillcutoff 1.5 assign uphillcost 0 assign uphillcutoff 1.5 +assign turnInstructionMode = 1 # 0=none, 1=auto-choose, 2=locus-style, 3=osmand-style assign validForFoot 1 ---context:way # following code refers to way-tags @@ -64,6 +65,47 @@ assign costfactor switch or highway=proposed highway=abandoned 100000 1 +# way priorities used for voice hint generation + +assign priorityclassifier = + + if ( highway=motorway ) then 30 + else if ( highway=motorway_link ) then 29 + else if ( highway=trunk ) then 28 + else if ( highway=trunk_link ) then 27 + else if ( highway=primary ) then 26 + else if ( highway=primary_link ) then 25 + else if ( highway=secondary ) then 24 + else if ( highway=secondary_link ) then 23 + else if ( highway=tertiary ) then 22 + else if ( highway=tertiary_link ) then 21 + else if ( highway=unclassified ) then 20 + else if ( highway=residential|living_street ) then 6 + else if ( highway=service ) then 6 + else if ( highway=cycleway ) then 6 + else if ( bicycle=designated ) then 6 + else if ( highway=track ) then if tracktype=grade1 then 6 else 4 + else if ( highway=bridleway|road|path|footway ) then 4 + else if ( highway=steps ) then 2 + else if ( highway=pedestrian ) then 2 + else 0 + +# some more classifying bits used for voice hint generation... + +assign isroundabout = junction=roundabout +assign islinktype = highway=motorway_link|trunk_link|primary_link|secondary_link|tertiary_link +assign isgoodforcars = if greater priorityclassifier 6 then true + else if highway=residential|living_street|service then true + else if ( and highway=track tracktype=grade1 ) then true + else false + + +# ... encoded into a bitmask + +assign classifiermask add multiply isroundabout 4 + add multiply islinktype 8 + multiply isgoodforcars 16 + ---context:node # following code refers to node tags assign defaultaccess