From a2360a241d3c379c0a85fd69fc7f8b93f0275ea8 Mon Sep 17 00:00:00 2001 From: Vladimir Byko-Ianko Date: Fri, 21 Jun 2019 07:04:42 +0300 Subject: [PATCH] [routing] Making kBicycleOptionsPedestrianFootwayAllowed for Belarus and Russia. --- routing_common/bicycle_model.cpp | 48 +++++++++++++++++--------------- 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/routing_common/bicycle_model.cpp b/routing_common/bicycle_model.cpp index 357261f287..941a955fb9 100644 --- a/routing_common/bicycle_model.cpp +++ b/routing_common/bicycle_model.cpp @@ -168,6 +168,29 @@ VehicleModel::LimitsInitList const kBicycleOptionsBridlewayAllowed = { {{"highway", "steps"}, true}, {{"highway", "platform"}, true}}; +// Same as defaults except pedestrian and footway are allowed +VehicleModel::LimitsInitList const kBicycleOptionsPedestrianFootwayAllowed = { + {{"highway", "trunk"}, true}, + {{"highway", "trunk_link"}, true}, + {{"highway", "primary"}, true}, + {{"highway", "primary_link"}, true}, + {{"highway", "secondary"}, true}, + {{"highway", "secondary_link"}, true}, + {{"highway", "tertiary"}, true}, + {{"highway", "tertiary_link"}, true}, + {{"highway", "service"}, true}, + {{"highway", "unclassified"}, true}, + {{"highway", "road"}, true}, + {{"highway", "track"}, true}, + {{"highway", "path"}, true}, + {{"highway", "cycleway"}, true}, + {{"highway", "residential"}, true}, + {{"highway", "living_street"}, true}, + {{"highway", "steps"}, true}, + {{"highway", "pedestrian"}, true}, + {{"highway", "footway"}, true}, + {{"highway", "platform"}, true}}; + // Australia VehicleModel::LimitsInitList const kBicycleOptionsAustralia = kBicycleOptionsAll; @@ -191,28 +214,7 @@ VehicleModel::LimitsInitList const kBicycleOptionsAustria = { {{"highway", "platform"}, true}}; // Belarus -VehicleModel::LimitsInitList const kBicycleOptionsBelarus = { - // Footway and pedestrian are allowed - {{"highway", "trunk"}, true}, - {{"highway", "trunk_link"}, true}, - {{"highway", "primary"}, true}, - {{"highway", "primary_link"}, true}, - {{"highway", "secondary"}, true}, - {{"highway", "secondary_link"}, true}, - {{"highway", "tertiary"}, true}, - {{"highway", "tertiary_link"}, true}, - {{"highway", "service"}, true}, - {{"highway", "unclassified"}, true}, - {{"highway", "road"}, true}, - {{"highway", "track"}, true}, - {{"highway", "path"}, true}, - {{"highway", "cycleway"}, true}, - {{"highway", "residential"}, true}, - {{"highway", "living_street"}, true}, - {{"highway", "steps"}, true}, - {{"highway", "pedestrian"}, true}, - {{"highway", "footway"}, true}, - {{"highway", "platform"}, true}}; +VehicleModel::LimitsInitList const kBicycleOptionsBelarus = kBicycleOptionsPedestrianFootwayAllowed; // Belgium VehicleModel::LimitsInitList const kBicycleOptionsBelgium = { @@ -318,7 +320,7 @@ VehicleModel::LimitsInitList const kBicycleOptionsRomania = kBicycleOptionsNoTru // https://wiki.openstreetmap.org/wiki/OSM_tags_for_routing/Access-Restrictions // passing through service and living_street with a bicycle is prohibited // it's allowed according to Russian traffic rules. -VehicleModel::LimitsInitList const kBicycleOptionsRussia = kBicycleOptionsBelarus; +VehicleModel::LimitsInitList const kBicycleOptionsRussia = kBicycleOptionsPedestrianFootwayAllowed; // Slovakia VehicleModel::LimitsInitList const kBicycleOptionsSlovakia = kBicycleOptionsNoTrunk;