mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-20 13:23:59 +00:00
Organic Maps sources as of 02.04.2025 (fad26bbf22ac3da75e01e62aa01e5c8e11861005)
To expand with full Organic Maps and Maps.ME commits history run: git remote add om-historic [om-historic.git repo url] git fetch --tags om-historic git replace squashed-history historic-commits
This commit is contained in:
56
routing/junction_visitor.cpp
Normal file
56
routing/junction_visitor.cpp
Normal file
@@ -0,0 +1,56 @@
|
||||
#include "junction_visitor.hpp"
|
||||
|
||||
#include "routing/joint_segment.hpp"
|
||||
#include "routing/route_weight.hpp"
|
||||
|
||||
#include "base/logging.hpp"
|
||||
|
||||
namespace routing
|
||||
{
|
||||
|
||||
#ifdef DEBUG
|
||||
// Leaps algorithm.
|
||||
void DebugRoutingState(Segment const & vertex, std::optional<Segment> const & parent,
|
||||
RouteWeight const & heuristic, RouteWeight const & distance)
|
||||
{
|
||||
// 1. Dump current processing vertex.
|
||||
// std::cout << DebugPrint(vertex);
|
||||
// std::cout << std::setprecision(8) << "; H = " << heuristic << "; D = " << distance;
|
||||
|
||||
// 2. Dump parent vertex.
|
||||
// std::cout << "; P = " << (parent ? DebugPrint(*parent) : std::string("NO"));
|
||||
|
||||
// std::cout << std::endl;
|
||||
}
|
||||
|
||||
// Joints algorithm.
|
||||
void DebugRoutingState(JointSegment const & vertex, std::optional<JointSegment> const & parent,
|
||||
RouteWeight const & heuristic, RouteWeight const & distance)
|
||||
{
|
||||
// 1. Dump current processing vertex.
|
||||
// std::cout << DebugPrint(vertex);
|
||||
// std::cout << std::setprecision(8) << "; H = " << heuristic << "; D = " << distance;
|
||||
|
||||
// 2. Dump parent vertex.
|
||||
// std::cout << "; P = " << (parent ? DebugPrint(*parent) : std::string("NO"));
|
||||
|
||||
// std::cout << std::endl;
|
||||
|
||||
// 3. Set breakpoint on a specific vertex.
|
||||
// if (vertex.GetMwmId() == 400 && vertex.GetFeatureId() == 2412 &&
|
||||
// vertex.GetEndSegmentId() == 0)
|
||||
// {
|
||||
// int noop = 0;
|
||||
// }
|
||||
|
||||
// 4. Set breakpoint when MWM was changed.
|
||||
// if (parent)
|
||||
// {
|
||||
// auto const & p = *parent;
|
||||
// if (!p.IsFake() && !vertex.IsFake() && p.GetMwmId() != vertex.GetMwmId())
|
||||
// int noop = 0;
|
||||
// }
|
||||
}
|
||||
#endif
|
||||
|
||||
} // namespace routing
|
||||
Reference in New Issue
Block a user