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 (PlanRepUML &PG, OrthoRep &OR, const RoutingChannel< int > &rc, GridLayoutMapped &drawing) |
| Constructive heurisitic for orthogonal representations. | |
| void | improvementHeuristics (PlanRepUML &PG, OrthoRep &OR, const RoutingChannel< int > &rc, GridLayoutMapped &drawing) |
| Improvement heurisitic for orthogonal drawings. | |
| void | tighten (bool select) |
| Sets option tighten to select. | |
| bool | tighten () const |
| Returns the option tighten. | |
| void | maxImprovementSteps (int maxSteps) |
| Sets the option max improvement steps. | |
| int | maxImprovementSteps () const |
| Returns the option max improvement steps. | |
Private Member Functions | |
| void | computeCoords (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
| void | applyLongestPaths (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
| void | moveComponents (const CompactionConstraintGraph< int > &D, NodeArray< int > &pos) |
Private Attributes | |
| bool | m_tighten |
| Tighten pseudo-components. | |
| int | m_maxImprovementSteps |
| The maximal number of improvement steps. | |
| SList< node > | m_pseudoSources |
| The list of pseudo-sources. | |
| NodeArray< int > | m_component |
| The pseudo component of a node. | |
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 93 of file LongestPathCompaction.h.
| ogdf::LongestPathCompaction::LongestPathCompaction | ( | bool | tighten = true, |
|
| int | maxImprovementSteps = 0 | |||
| ) |
Creates an instance of the longest path compaction algorithm.
| void ogdf::LongestPathCompaction::applyLongestPaths | ( | const CompactionConstraintGraph< int > & | D, | |
| NodeArray< int > & | pos | |||
| ) | [private] |
| void ogdf::LongestPathCompaction::computeCoords | ( | const CompactionConstraintGraph< int > & | D, | |
| NodeArray< int > & | pos | |||
| ) | [private] |
| void ogdf::LongestPathCompaction::constructiveHeuristics | ( | PlanRepUML & | PG, | |
| OrthoRep & | OR, | |||
| const RoutingChannel< int > & | rc, | |||
| GridLayoutMapped & | drawing | |||
| ) |
Constructive heurisitic for orthogonal representations.
| void ogdf::LongestPathCompaction::improvementHeuristics | ( | PlanRepUML & | PG, | |
| OrthoRep & | OR, | |||
| const RoutingChannel< int > & | rc, | |||
| GridLayoutMapped & | drawing | |||
| ) |
Improvement heurisitic for orthogonal drawings.
| void ogdf::LongestPathCompaction::maxImprovementSteps | ( | int | maxSteps | ) | [inline] |
Sets the option max improvement steps.
Definition at line 130 of file LongestPathCompaction.h.
| int ogdf::LongestPathCompaction::maxImprovementSteps | ( | ) | const [inline] |
Returns the option max improvement steps.
Definition at line 135 of file LongestPathCompaction.h.
| void ogdf::LongestPathCompaction::moveComponents | ( | const CompactionConstraintGraph< int > & | D, | |
| NodeArray< int > & | pos | |||
| ) | [private] |
| bool ogdf::LongestPathCompaction::tighten | ( | ) | const [inline] |
Returns the option tighten.
Definition at line 124 of file LongestPathCompaction.h.
| void ogdf::LongestPathCompaction::tighten | ( | bool | select | ) | [inline] |
Sets option tighten to select.
Definition at line 119 of file LongestPathCompaction.h.
NodeArray<int> ogdf::LongestPathCompaction::m_component [private] |
The pseudo component of a node.
Definition at line 157 of file LongestPathCompaction.h.
int ogdf::LongestPathCompaction::m_maxImprovementSteps [private] |
The maximal number of improvement steps.
Definition at line 154 of file LongestPathCompaction.h.
The list of pseudo-sources.
Definition at line 156 of file LongestPathCompaction.h.
bool ogdf::LongestPathCompaction::m_tighten [private] |
Tighten pseudo-components.
Definition at line 153 of file LongestPathCompaction.h.