From 849baea544af50d359a4ff36dc2926f9ef72a6b7 Mon Sep 17 00:00:00 2001 From: Patrick Niklaus Date: Tue, 5 Apr 2016 13:59:51 +0200 Subject: [PATCH] Fix uturn detection in match plugin --- src/engine/plugins/match.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/engine/plugins/match.cpp b/src/engine/plugins/match.cpp index 1fff3fefc..029a27eb3 100644 --- a/src/engine/plugins/match.cpp +++ b/src/engine/plugins/match.cpp @@ -183,7 +183,9 @@ Status MatchPlugin::HandleRequest(const api::MatchParameters ¶meters, BOOST_ASSERT(current_phantom_node_pair.target_phantom.IsValid()); sub_routes[index].segment_end_coordinates.emplace_back(current_phantom_node_pair); } - shortest_path(sub_routes[index].segment_end_coordinates, {}, sub_routes[index]); + // force uturns to be on, since we split the phantom nodes anyway and only have bi-directional + // phantom nodes for possible uturns + shortest_path(sub_routes[index].segment_end_coordinates, {true}, sub_routes[index]); BOOST_ASSERT(sub_routes[index].shortest_path_length != INVALID_EDGE_WEIGHT); }