Compaction algorithm using longest paths in the constraint graph. More...
#include <ogdf/orthogonal/LongestPathCompaction.h>
Public Member Functions | |
LongestPathCompaction (bool tighten=true, int maxImprovementSteps=0) | |
Creates an instance of the longest path compaction algorithm. | |
void | constructiveHeuristics (PlanRep &PG, OrthoRep &OR, const RoutingChannel< int > &rc, GridLayoutMapped &drawing) |
Constructive heurisitic for orthogonal representations. | |
void | improvementHeuristics (PlanRep &PG, OrthoRep &OR, const RoutingChannel< int > &rc, GridLayoutMapped &drawing) |
Improvement heurisitic for orthogonal drawings. | |
int | maxImprovementSteps () const |
Returns the option max improvement steps. | |
void | maxImprovementSteps (int maxSteps) |
Sets the option max improvement steps. | |
bool | tighten () const |
Returns the option tighten. | |
void | tighten (bool select) |
Sets option tighten to select . | |
Private Member Functions | |
void | applyLongestPaths (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
void | computeCoords (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
void | moveComponents (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
Private Attributes | |
NodeArray< int > | m_component |
The pseudo component of a node. | |
int | m_maxImprovementSteps |
The maximal number of improvement steps. | |
SList< node > | m_pseudoSources |
The list of pseudo-sources. | |
bool | m_tighten |
Tighten pseudo-components. | |
Compaction algorithm using longest paths in the constraint graph.
Option | Type | Default | Description |
---|---|---|---|
tighten | bool | true | if true, an additional improvement step tries to reduce the total edge length |
max improvement steps | int | 0 | the maximal number of steps performed by the improvement heuristic; 0 means no upper limit. |
Definition at line 63 of file LongestPathCompaction.h.
|
explicit |
Creates an instance of the longest path compaction algorithm.
|
private |
|
private |
void ogdf::LongestPathCompaction::constructiveHeuristics | ( | PlanRep & | PG, |
OrthoRep & | OR, | ||
const RoutingChannel< int > & | rc, | ||
GridLayoutMapped & | drawing | ||
) |
Constructive heurisitic for orthogonal representations.
void ogdf::LongestPathCompaction::improvementHeuristics | ( | PlanRep & | PG, |
OrthoRep & | OR, | ||
const RoutingChannel< int > & | rc, | ||
GridLayoutMapped & | drawing | ||
) |
Improvement heurisitic for orthogonal drawings.
|
inline |
Returns the option max improvement steps.
Definition at line 90 of file LongestPathCompaction.h.
Sets the option max improvement steps.
Definition at line 87 of file LongestPathCompaction.h.
|
private |
|
inline |
Returns the option tighten.
Definition at line 84 of file LongestPathCompaction.h.
Sets option tighten to select
.
Definition at line 81 of file LongestPathCompaction.h.
The pseudo component of a node.
Definition at line 106 of file LongestPathCompaction.h.
|
private |
The maximal number of improvement steps.
Definition at line 103 of file LongestPathCompaction.h.
The list of pseudo-sources.
Definition at line 105 of file LongestPathCompaction.h.
|
private |
Tighten pseudo-components.
Definition at line 102 of file LongestPathCompaction.h.