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

Function IsValidSplineTurn

libs/drape_frontend/path_text_handle.cpp:81–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

79} // namespace
80
81bool IsValidSplineTurn(m2::PointD const & normalizedDir1, m2::PointD const & normalizedDir2)
82{
83 double const dotProduct = m2::DotProduct(normalizedDir1, normalizedDir2);
84 double constexpr kEps = 1e-5;
85 return dotProduct > kCosTurn || fabs(dotProduct - kCosTurn) < kEps;
86}
87
88void AddPointAndRound(m2::SplineEx & spline, m2::PointD const & pt)
89{

Callers 2

RoundCornerFunction · 0.85
IsSmoothFunction · 0.85

Calls 1

DotProductFunction · 0.50

Tested by 1

IsSmoothFunction · 0.68