improve collapse-handling

This commit is contained in:
Moritz Kobitzsch
2016-05-30 17:42:28 +02:00
parent dfafe7dc5f
commit 1dfdb38d4a
18 changed files with 409 additions and 157 deletions
+1
View File
@@ -144,6 +144,7 @@ class RouteAPI : public BaseAPI
guidance::trimShortSegments(steps, leg_geometry);
leg.steps = guidance::postProcess(std::move(steps));
leg.steps = guidance::collapseTurns(std::move(leg.steps));
leg.steps = guidance::buildIntersections(std::move(leg.steps));
leg.steps = guidance::assignRelativeLocations(std::move(leg.steps),
leg_geometry,
phantoms.source_phantom,
@@ -37,6 +37,9 @@ std::vector<RouteStep> assignRelativeLocations(std::vector<RouteStep> steps,
const PhantomNode &source_node,
const PhantomNode &target_node);
// collapse suppressed instructions remaining into intersections array
std::vector<RouteStep> buildIntersections(std::vector<RouteStep> steps);
// remove steps invalidated by post-processing
std::vector<RouteStep> removeNoTurnInstructions(std::vector<RouteStep> steps);