added profiles and readmes
This commit is contained in:
parent
5453c7b2f8
commit
2edac085d0
10 changed files with 1542 additions and 0 deletions
225
misc/profiles2/trekking.brf
Normal file
225
misc/profiles2/trekking.brf
Normal file
|
|
@ -0,0 +1,225 @@
|
|||
# *** The trekking profile is for slow travel
|
||||
# *** and avoiding car traffic, but still with
|
||||
# *** a focus on approaching your destination
|
||||
# *** efficiently.
|
||||
|
||||
---context:global # following code refers to global config
|
||||
|
||||
# Use the following switches to change behaviour
|
||||
# (1=yes, 0=no):
|
||||
|
||||
assign consider_elevation 1 # set to 0 to ignore elevation in routing
|
||||
assign allow_steps 1 # set to 0 to disallow steps
|
||||
assign allow_ferries 1 # set to 0 to disallow ferries
|
||||
assign ignore_cycleroutes 0 # set to 1 for better elevation results
|
||||
assign stick_to_cycleroutes 0 # set to 1 to just follow cycleroutes
|
||||
assign avoid_unsafe 0 # set to 1 to avoid standard highways
|
||||
|
||||
assign validForBikes 1
|
||||
|
||||
# the elevation parameters
|
||||
|
||||
assign downhillcost switch consider_elevation 60 0
|
||||
assign downhillcutoff 1.5
|
||||
assign uphillcost 0
|
||||
assign uphillcutoff 1.5
|
||||
|
||||
---context:way # following code refers to way-tags
|
||||
|
||||
#
|
||||
# pre-calculate some logical expressions
|
||||
#
|
||||
assign is_ldcr and longdistancecycleway=yes not ignore_cycleroutes
|
||||
assign isbike or bicycle=yes or bicycle=designated lcn=yes
|
||||
assign ispaved or surface=paved or surface=asphalt or surface=concrete surface=paving_stones
|
||||
assign isunpaved not or surface= or ispaved or surface=fine_gravel surface=cobblestone
|
||||
assign probablyGood or ispaved and isbike not isunpaved
|
||||
|
||||
|
||||
#
|
||||
# this is the cost (in Meter) for a 90-degree turn
|
||||
# The actual cost is calculated as turncost*cos(angle)
|
||||
# (Suppressing turncost while following longdistance-cycleways
|
||||
# makes them a little bit more magnetic)
|
||||
#
|
||||
assign turncost switch is_ldcr 0 90
|
||||
|
||||
#
|
||||
# calculate the initial cost
|
||||
# this is added to the total cost each time the costfactor
|
||||
# changed
|
||||
#
|
||||
assign initialcost switch highway=ferry 10000 0
|
||||
|
||||
#
|
||||
# implicit access here just from the motorroad tag
|
||||
# (implicit access rules from highway tag handled elsewhere)
|
||||
#
|
||||
assign defaultaccess
|
||||
switch access=
|
||||
not motorroad=yes
|
||||
switch or access=private access=no
|
||||
0
|
||||
1
|
||||
|
||||
#
|
||||
# calculate logical bike access
|
||||
#
|
||||
assign bikeaccess
|
||||
or longdistancecycleway=yes
|
||||
switch bicycle=
|
||||
switch vehicle=
|
||||
defaultaccess
|
||||
switch or vehicle=private vehicle=no
|
||||
0
|
||||
1
|
||||
not or bicycle=private or bicycle=no bicycle=dismount
|
||||
|
||||
#
|
||||
# calculate logical foot access
|
||||
#
|
||||
assign footaccess
|
||||
or bikeaccess
|
||||
or bicycle=dismount
|
||||
switch foot=
|
||||
defaultaccess
|
||||
not or foot=private foot=no
|
||||
|
||||
#
|
||||
# if not bike-, but foot-acess, just a moderate penalty,
|
||||
# otherwise access is forbidden
|
||||
#
|
||||
assign accesspenalty
|
||||
switch bikeaccess
|
||||
0
|
||||
switch footaccess
|
||||
4
|
||||
100000
|
||||
|
||||
#
|
||||
# handle one-ways. On primary roads, wrong-oneways should
|
||||
# be close to forbidden, while on other ways we just add
|
||||
# 4 to the costfactor (making it at least 5 - you are allowed
|
||||
# to push your bike)
|
||||
#
|
||||
assign oneway
|
||||
switch oneway=
|
||||
junction=roundabout
|
||||
or oneway=yes or oneway=true oneway=1
|
||||
assign onewaypenalty
|
||||
switch switch reversedirection=yes oneway oneway=-1
|
||||
switch or cycleway=opposite or cycleway=opposite_lane cycleway=opposite_track 0
|
||||
switch or highway=primary highway=primary_link 50
|
||||
switch or highway=secondary highway=secondary_link 30
|
||||
switch or highway=tertiary highway=tertiary_link 20
|
||||
4.0
|
||||
0.0
|
||||
|
||||
#
|
||||
# calculate the cost-factor, which is the factor
|
||||
# by which the distance of a way-segment is multiplied
|
||||
# to calculate the cost of that segment. The costfactor
|
||||
# must be >=1 and it's supposed to be close to 1 for
|
||||
# the type of way the routing profile is searching for
|
||||
#
|
||||
assign costfactor
|
||||
|
||||
add max onewaypenalty accesspenalty
|
||||
|
||||
#
|
||||
# steps and ferries are special. Note this is handled
|
||||
# before the longdistancecycleway-switch, to be able
|
||||
# to really exlude them be setting cost to infinity
|
||||
#
|
||||
switch highway=steps switch allow_steps 40 100000
|
||||
switch highway=ferry switch allow_ferries 5.67 100000
|
||||
|
||||
#
|
||||
# handle long-distance cycle-routes.
|
||||
#
|
||||
switch is_ldcr 1 # always treated as perfect (=1)
|
||||
add switch stick_to_cycleroutes 0.5 0.05 # everything else somewhat up
|
||||
|
||||
#
|
||||
# some other highway types
|
||||
#
|
||||
switch highway=pedestrian 3
|
||||
switch highway=bridleway 5
|
||||
switch highway=cycleway 1
|
||||
switch or highway=residential highway=living_street switch isunpaved 1.5 1.1
|
||||
switch highway=service switch isunpaved 1.6 1.3
|
||||
|
||||
#
|
||||
# tracks and track-like ways are rated mainly be tracktype/grade
|
||||
# But note that if no tracktype is given (mainly for road/path/footway)
|
||||
# it can be o.k. if there's any other hint for quality
|
||||
#
|
||||
switch or highway=track or highway=road or highway=path highway=footway
|
||||
switch tracktype=grade1 switch probablyGood 1.0 1.3
|
||||
switch tracktype=grade2 switch probablyGood 1.1 2.0
|
||||
switch tracktype=grade3 switch probablyGood 1.5 3.0
|
||||
switch tracktype=grade4 switch probablyGood 2.0 5.0
|
||||
switch tracktype=grade5 switch probablyGood 3.0 5.0
|
||||
switch probablyGood 1.0 5.0
|
||||
|
||||
#
|
||||
# When avoiding unsafe ways, avoid highways without a bike hint
|
||||
#
|
||||
add switch and avoid_unsafe not isbike 2 0
|
||||
|
||||
#
|
||||
# exclude motorways and proposed roads
|
||||
#
|
||||
switch or highway=motorway highway=motorway_link 100000
|
||||
switch highway=proposed 100000
|
||||
|
||||
#
|
||||
# actuals roads are o.k. if we have a bike hint
|
||||
#
|
||||
switch or highway=trunk highway=trunk_link switch isbike 1.5 10
|
||||
switch or highway=primary highway=primary_link switch isbike 1.2 3
|
||||
switch or highway=secondary highway=secondary_link switch isbike 1.1 1.6
|
||||
switch or highway=tertiary highway=tertiary_link switch isbike 1.0 1.4
|
||||
switch highway=unclassified switch isbike 1.0 1.3
|
||||
|
||||
#
|
||||
# default for any other highway type not handled above
|
||||
#
|
||||
2.0
|
||||
|
||||
|
||||
---context:node # following code refers to node tags
|
||||
|
||||
assign defaultaccess
|
||||
switch access=
|
||||
1 # add default barrier restrictions here!
|
||||
switch or access=private access=no
|
||||
0
|
||||
1
|
||||
|
||||
assign bikeaccess
|
||||
or or longdistancecycleway=yes lcn=yes
|
||||
switch bicycle=
|
||||
switch vehicle=
|
||||
defaultaccess
|
||||
switch or vehicle=private vehicle=no
|
||||
0
|
||||
1
|
||||
switch or bicycle=private or bicycle=no bicycle=dismount
|
||||
0
|
||||
1
|
||||
|
||||
assign footaccess
|
||||
or bicycle=dismount
|
||||
switch foot=
|
||||
defaultaccess
|
||||
switch or foot=private foot=no
|
||||
0
|
||||
1
|
||||
|
||||
assign initialcost
|
||||
switch bikeaccess
|
||||
0
|
||||
switch footaccess
|
||||
100
|
||||
1000000
|
||||
Loading…
Add table
Add a link
Reference in a new issue