MCPcopy Create free account
hub / github.com/comaps/comaps / GetStartLines

Method GetStartLines

tools/openlr/candidate_paths_getter.cpp:98–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96}
97
98void CandidatePathsGetter::GetStartLines(vector<m2::PointD> const & points, bool const isLastPoint,
99 Graph::EdgeVector & edges)
100{
101 for (auto const & pc : points)
102 {
103 Graph::EdgeListT tmp;
104 if (!isLastPoint)
105 m_graph.GetOutgoingEdges(geometry::PointWithAltitude(pc, 0 /* altitude */), tmp);
106 else
107 m_graph.GetIngoingEdges(geometry::PointWithAltitude(pc, 0 /* altitude */), tmp);
108
109 edges.insert(edges.end(), tmp.begin(), tmp.end());
110 }
111
112 // Same edges may start on different points if those points are close enough.
113 base::SortUnique(edges, less<Graph::Edge>(), EdgesAreAlmostEqual);
114}
115
116void CandidatePathsGetter::GetAllSuitablePaths(Graph::EdgeVector const & startLines, bool isLastPoint, double bearDistM,
117 FunctionalRoadClass functionalRoadClass, FormOfWay formOfWay,

Callers

nothing calls this directly

Calls 7

SortUniqueFunction · 0.85
PointWithAltitudeClass · 0.50
GetOutgoingEdgesMethod · 0.45
GetIngoingEdgesMethod · 0.45
insertMethod · 0.45
endMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected