Take stop signs into account during routing
This commit is contained in:
@@ -71,6 +71,7 @@ class EdgeBasedGraphFactory
|
||||
const std::unordered_set<NodeID> &barrier_nodes,
|
||||
const TrafficFlowControlNodes &traffic_signals,
|
||||
const TrafficFlowControlNodes &stop_signs,
|
||||
const TrafficFlowControlNodes &give_way_signs,
|
||||
const std::vector<util::Coordinate> &coordinates,
|
||||
const NameTable &name_table,
|
||||
const std::unordered_set<EdgeID> &segregated_edges,
|
||||
@@ -138,6 +139,7 @@ class EdgeBasedGraphFactory
|
||||
const std::unordered_set<NodeID> &m_barrier_nodes;
|
||||
const TrafficFlowControlNodes &m_traffic_signals;
|
||||
const TrafficFlowControlNodes &m_stop_signs;
|
||||
const TrafficFlowControlNodes &m_give_way_signs;
|
||||
|
||||
const CompressedEdgeContainer &m_compressed_edge_container;
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ class ExtractionContainers
|
||||
ReferencedWays IdentifyManeuverOverrideWays();
|
||||
|
||||
ReferencedTrafficFlowControlNodes IdentifyTrafficFlowControlNodes(
|
||||
const std::vector<InputTrafficFlowControlNode> &external_stop_signs);
|
||||
const std::vector<InputTrafficFlowControlNode> &external_traffic_control_nodes);
|
||||
|
||||
void PrepareNodes();
|
||||
void PrepareManeuverOverrides(const ReferencedWays &maneuver_override_ways);
|
||||
@@ -83,7 +83,7 @@ class ExtractionContainers
|
||||
TrafficFlowControlNodes internal_stop_signs;
|
||||
|
||||
std::vector<InputTrafficFlowControlNode> external_give_ways;
|
||||
TrafficFlowControlNodes internal_give_ways;
|
||||
TrafficFlowControlNodes internal_give_way_signs;
|
||||
|
||||
std::vector<NodeBasedEdge> used_edges;
|
||||
|
||||
|
||||
@@ -52,6 +52,7 @@ struct ExtractionTurn
|
||||
bool is_u_turn,
|
||||
bool has_traffic_light,
|
||||
bool has_stop_sign,
|
||||
bool has_give_way_sign,
|
||||
bool is_left_hand_driving,
|
||||
bool source_restricted,
|
||||
TravelMode source_mode,
|
||||
@@ -76,7 +77,7 @@ struct ExtractionTurn
|
||||
const std::vector<ExtractionTurnLeg> &roads_on_the_right,
|
||||
const std::vector<ExtractionTurnLeg> &roads_on_the_left)
|
||||
: angle(180. - angle), number_of_roads(number_of_roads), is_u_turn(is_u_turn),
|
||||
has_traffic_light(has_traffic_light), has_stop_sign(has_stop_sign),
|
||||
has_traffic_light(has_traffic_light), has_stop_sign(has_stop_sign), has_give_way_sign(has_give_way_sign),
|
||||
is_left_hand_driving(is_left_hand_driving),
|
||||
|
||||
source_restricted(source_restricted), source_mode(source_mode),
|
||||
@@ -103,6 +104,7 @@ struct ExtractionTurn
|
||||
const bool is_u_turn;
|
||||
const bool has_traffic_light;
|
||||
const bool has_stop_sign;
|
||||
const bool has_give_way_sign;
|
||||
const bool is_left_hand_driving;
|
||||
|
||||
// source info
|
||||
|
||||
@@ -68,6 +68,7 @@ class Extractor
|
||||
std::vector<UnresolvedManeuverOverride> unresolved_maneuver_overrides;
|
||||
TrafficFlowControlNodes traffic_signals;
|
||||
TrafficFlowControlNodes stop_signs;
|
||||
TrafficFlowControlNodes give_way_signs;
|
||||
std::unordered_set<NodeID> barriers;
|
||||
std::vector<util::Coordinate> osm_coordinates;
|
||||
extractor::PackedOSMIDs osm_node_ids;
|
||||
@@ -89,6 +90,7 @@ class Extractor
|
||||
const std::unordered_set<NodeID> &barrier_nodes,
|
||||
const TrafficFlowControlNodes &traffic_signals,
|
||||
const TrafficFlowControlNodes &stop_signs,
|
||||
const TrafficFlowControlNodes &give_way_signs,
|
||||
const RestrictionGraph &restriction_graph,
|
||||
const std::unordered_set<EdgeID> &segregated_edges,
|
||||
const NameTable &name_table,
|
||||
|
||||
@@ -28,6 +28,7 @@ class GraphCompressor
|
||||
void Compress(const std::unordered_set<NodeID> &barrier_nodes,
|
||||
const TrafficFlowControlNodes &traffic_signals,
|
||||
const TrafficFlowControlNodes &stop_signs,
|
||||
const TrafficFlowControlNodes &give_way_signs,
|
||||
ScriptingEnvironment &scripting_environment,
|
||||
std::vector<TurnRestriction> &turn_restrictions,
|
||||
std::vector<UnresolvedManeuverOverride> &maneuver_overrides,
|
||||
|
||||
@@ -43,7 +43,7 @@ class NodeBasedGraphFactory
|
||||
std::vector<UnresolvedManeuverOverride> &maneuver_overrides,
|
||||
const TrafficFlowControlNodes &traffic_signals,
|
||||
const TrafficFlowControlNodes &stop_signs,
|
||||
|
||||
const TrafficFlowControlNodes &give_way_signs,
|
||||
std::unordered_set<NodeID> &&barriers,
|
||||
std::vector<util::Coordinate> &&coordinates,
|
||||
extractor::PackedOSMIDs &&osm_node_ids,
|
||||
@@ -76,7 +76,8 @@ class NodeBasedGraphFactory
|
||||
std::vector<TurnRestriction> &turn_restrictions,
|
||||
std::vector<UnresolvedManeuverOverride> &maneuver_overrides,
|
||||
const TrafficFlowControlNodes &traffic_signals,
|
||||
const TrafficFlowControlNodes &stop_signs);
|
||||
const TrafficFlowControlNodes &stop_signs,
|
||||
const TrafficFlowControlNodes &give_way_signs);
|
||||
|
||||
// Most ways are bidirectional, making the geometry in forward and backward direction the same,
|
||||
// except for reversal. We make use of this fact by keeping only one representation of the
|
||||
|
||||
Reference in New Issue
Block a user