![]() |
hivemind 1.0.0
|
Represents a node in a Graph data structured made for path-finding. More...
#include <graph.h>
Public Attributes | |
T | Data |
Data stored in the the node. | |
std::weak_ptr< Node< T > > | Parent |
A non-owner pointer to the parent of the node. | |
bool | Visited |
Specifies if a given node has been visited during path-finding. | |
double | GlobalGoal |
Represents the assumed cost from the start to the goal node through this node. | |
double | LocalGoal |
Represents the cost from the start node to this node. | |
Represents a node in a Graph data structured made for path-finding.
T | Type of data to store inside the node |
T Routemaker::Node< T >::Data |
Data stored in the the node.
Stores data not needed by the A* path-finding algorithm. This is what the user actually wants to store in the Graph.
Definition at line 23 of file graph.h.
Referenced by Routemaker::Routemaker::UpdateOrigin().
double Routemaker::Node< T >::GlobalGoal |
Represents the assumed cost from the start to the goal node through this node.
Should not be set by the user. The A* path-finding algorithm uses cost to find the shortest path in a reasonable amount of time. This member contains the sum of the cost to get to this node from the start node, represented in LocalGoal, plus the assumed cost to get from this node to the goal node. The A* path-finding algorithm uses this value during Graph traversal to sort a priority queue in order to explore the assumed shortest paths first.
double Routemaker::Node< T >::LocalGoal |
Represents the cost from the start node to this node.
Should not be set by the user. The A* path-finding algorithm uses cost to find the shortest path in a reasonable amount of time. This member contains the sum of the cost to get to this node from the start node. While traversing the Graph, the A* path-finding algorithm updates and uses this member to check for shorter paths.
std::weak_ptr<Node<T> > Routemaker::Node< T >::Parent |
bool Routemaker::Node< T >::Visited |
Specifies if a given node has been visited during path-finding.
Should not be set by user. Is generally only used internally by the A* path-finding algorithm when traversing the Graph. May be used in debug views to visualize which nodes are visited during path-finding.