A struct that provides the comparison of edge objects. It allows sorting of edges for priority queues. The sorting follows three rules: First, edges are sorted by ascending cost. Edges with the same cost are sorted preferring horizontal/vertical edges. Edges with same cost and orientation are sorted ascending by vertical/horizontal position. More...
#include <edge.h>
Public Member Functions | |
bool | operator() (const edge &a, const edge &b) const |
Compare two edge objects. Edges are compared in terms of cost, orientation, and the position. More... | |
A struct that provides the comparison of edge objects. It allows sorting of edges for priority queues. The sorting follows three rules: First, edges are sorted by ascending cost. Edges with the same cost are sorted preferring horizontal/vertical edges. Edges with same cost and orientation are sorted ascending by vertical/horizontal position.
Compare two edge objects. Edges are compared in terms of cost, orientation, and the position.
a | First edge. |
b | Second edge. |