Inkscape
Vector Graphics Editor
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages Concepts
Avoid::MinimumTerminalSpanningTree Class Reference

#include <mtst.h>

Public Member Functions

 MinimumTerminalSpanningTree (Router *router, std::set< VertInf * > terminals, JunctionHyperedgeTreeNodeMap *hyperedgeTreeJunctions=nullptr)
 
 ~MinimumTerminalSpanningTree ()
 
void constructInterleaved (void)
 
void constructSequential (void)
 
void setDebuggingOutput (FILE *fp, unsigned int counter)
 
HyperedgeTreeNoderootJunction (void) const
 

Private Member Functions

void buildHyperedgeTreeToRoot (VertInf *curr, HyperedgeTreeNode *prevNode, VertInf *prevVert, bool markEdges=false)
 
VertInf ** resetDistsForPath (VertInf *currVert, VertInf **newRootVertPtr)
 
void rewriteRestOfHyperedge (VertInf *vert, VertInf **newTreeRootPtr)
 
void drawForest (VertInf *vert, VertInf *prev)
 
void makeSet (VertInf *vertex)
 
VertexSetList::iterator findSet (VertInf *vertex)
 
void unionSets (VertexSetList::iterator s1, VertexSetList::iterator s2)
 
HyperedgeTreeNodeaddNode (VertInf *vertex, HyperedgeTreeNode *prevNode)
 
void removeInvalidBridgingEdges (void)
 
void commitToBridgingEdge (EdgeInf *e)
 
bool connectsWithoutBend (VertInf *oldLeaf, VertInf *newLeaf)
 
LayeredOrthogonalEdgeList getOrthogonalEdgesFromVertex (VertInf *vert, VertInf *prev)
 
VertInforthogonalPartner (VertInf *vert, double penalty=0)
 
VertexPair realVerticesCountingPartners (EdgeInf *edge)
 

Private Attributes

Routerrouter
 
bool isOrthogonal
 
std::set< VertInf * > terminals
 
std::set< VertInf * > origTerminals
 
JunctionHyperedgeTreeNodeMaphyperedgeTreeJunctions
 
VertexNodeMap nodes
 
HyperedgeTreeNodem_rootJunction
 
double bendPenalty
 
VertexSetList allsets
 
std::list< VertInf * > visitedVertices
 
std::list< VertInf * > extraVertices
 
std::list< VertInf * > unusedVertices
 
std::list< VertInf ** > rootVertexPointers
 
std::vector< VertInf * > vHeap
 
HeapCmpVertInf vHeapCompare
 
std::vector< EdgeInf * > beHeap
 
CmpEdgeInf beHeapCompare
 
const VertID dimensionChangeVertexID
 

Detailed Description

Definition at line 66 of file mtst.h.

Constructor & Destructor Documentation

◆ MinimumTerminalSpanningTree()

Avoid::MinimumTerminalSpanningTree::MinimumTerminalSpanningTree ( Router router,
std::set< VertInf * >  terminals,
JunctionHyperedgeTreeNodeMap hyperedgeTreeJunctions = nullptr 
)

Definition at line 76 of file mtst.cpp.

◆ ~MinimumTerminalSpanningTree()

Avoid::MinimumTerminalSpanningTree::~MinimumTerminalSpanningTree ( )

Definition at line 89 of file mtst.cpp.

References Avoid::HyperedgeTreeNode::deleteEdgesExcept(), and m_rootJunction.

Member Function Documentation

◆ addNode()

◆ buildHyperedgeTreeToRoot()

◆ commitToBridgingEdge()

◆ connectsWithoutBend()

bool Avoid::MinimumTerminalSpanningTree::connectsWithoutBend ( VertInf oldLeaf,
VertInf newLeaf 
)
private

◆ constructInterleaved()

◆ constructSequential()

◆ drawForest()

◆ findSet()

VertexSetList::iterator Avoid::MinimumTerminalSpanningTree::findSet ( VertInf vertex)
private

Definition at line 111 of file mtst.cpp.

References allsets.

Referenced by constructSequential().

◆ getOrthogonalEdgesFromVertex()

LayeredOrthogonalEdgeList Avoid::MinimumTerminalSpanningTree::getOrthogonalEdgesFromVertex ( VertInf vert,
VertInf prev 
)
private

◆ makeSet()

void Avoid::MinimumTerminalSpanningTree::makeSet ( VertInf vertex)
private

Definition at line 104 of file mtst.cpp.

References allsets.

Referenced by constructSequential().

◆ orthogonalPartner()

VertInf * Avoid::MinimumTerminalSpanningTree::orthogonalPartner ( VertInf vert,
double  penalty = 0 
)
private

◆ realVerticesCountingPartners()

◆ removeInvalidBridgingEdges()

void Avoid::MinimumTerminalSpanningTree::removeInvalidBridgingEdges ( void  )
private

Definition at line 543 of file mtst.cpp.

References beHeap, beHeapCompare, origTerminals, and realVerticesCountingPartners().

Referenced by constructInterleaved().

◆ resetDistsForPath()

VertInf ** Avoid::MinimumTerminalSpanningTree::resetDistsForPath ( VertInf currVert,
VertInf **  newRootVertPtr 
)
private

◆ rewriteRestOfHyperedge()

void Avoid::MinimumTerminalSpanningTree::rewriteRestOfHyperedge ( VertInf vert,
VertInf **  newTreeRootPtr 
)
private

◆ rootJunction()

HyperedgeTreeNode * Avoid::MinimumTerminalSpanningTree::rootJunction ( void  ) const

Definition at line 98 of file mtst.cpp.

References m_rootJunction.

Referenced by Avoid::HyperedgeRerouter::performRerouting().

◆ setDebuggingOutput()

void Avoid::MinimumTerminalSpanningTree::setDebuggingOutput ( FILE *  fp,
unsigned int  counter 
)

◆ unionSets()

void Avoid::MinimumTerminalSpanningTree::unionSets ( VertexSetList::iterator  s1,
VertexSetList::iterator  s2 
)
private

Definition at line 124 of file mtst.cpp.

References allsets.

Referenced by constructSequential().

Member Data Documentation

◆ allsets

VertexSetList Avoid::MinimumTerminalSpanningTree::allsets
private

Definition at line 114 of file mtst.h.

Referenced by constructSequential(), findSet(), makeSet(), and unionSets().

◆ beHeap

std::vector<EdgeInf *> Avoid::MinimumTerminalSpanningTree::beHeap
private

Definition at line 125 of file mtst.h.

Referenced by constructInterleaved(), constructSequential(), and removeInvalidBridgingEdges().

◆ beHeapCompare

CmpEdgeInf Avoid::MinimumTerminalSpanningTree::beHeapCompare
private

Definition at line 126 of file mtst.h.

Referenced by constructInterleaved(), constructSequential(), and removeInvalidBridgingEdges().

◆ bendPenalty

double Avoid::MinimumTerminalSpanningTree::bendPenalty
private

Definition at line 113 of file mtst.h.

Referenced by constructSequential(), and orthogonalPartner().

◆ dimensionChangeVertexID

const VertID Avoid::MinimumTerminalSpanningTree::dimensionChangeVertexID
private

◆ extraVertices

std::list<VertInf *> Avoid::MinimumTerminalSpanningTree::extraVertices
private

Definition at line 116 of file mtst.h.

Referenced by constructInterleaved(), constructSequential(), and orthogonalPartner().

◆ hyperedgeTreeJunctions

JunctionHyperedgeTreeNodeMap* Avoid::MinimumTerminalSpanningTree::hyperedgeTreeJunctions
private

Definition at line 109 of file mtst.h.

Referenced by commitToBridgingEdge(), and constructSequential().

◆ isOrthogonal

bool Avoid::MinimumTerminalSpanningTree::isOrthogonal
private

◆ m_rootJunction

HyperedgeTreeNode* Avoid::MinimumTerminalSpanningTree::m_rootJunction
private

Definition at line 112 of file mtst.h.

Referenced by addNode(), rootJunction(), and ~MinimumTerminalSpanningTree().

◆ nodes

VertexNodeMap Avoid::MinimumTerminalSpanningTree::nodes
private

Definition at line 111 of file mtst.h.

Referenced by addNode(), and constructSequential().

◆ origTerminals

std::set<VertInf *> Avoid::MinimumTerminalSpanningTree::origTerminals
private

Definition at line 108 of file mtst.h.

Referenced by commitToBridgingEdge(), constructInterleaved(), and removeInvalidBridgingEdges().

◆ rootVertexPointers

std::list<VertInf **> Avoid::MinimumTerminalSpanningTree::rootVertexPointers
private

Definition at line 118 of file mtst.h.

Referenced by commitToBridgingEdge(), and constructInterleaved().

◆ router

Router* Avoid::MinimumTerminalSpanningTree::router
private

◆ terminals

std::set<VertInf *> Avoid::MinimumTerminalSpanningTree::terminals
private

◆ unusedVertices

std::list<VertInf *> Avoid::MinimumTerminalSpanningTree::unusedVertices
private

Definition at line 117 of file mtst.h.

◆ vHeap

std::vector<VertInf *> Avoid::MinimumTerminalSpanningTree::vHeap
private

Definition at line 121 of file mtst.h.

Referenced by commitToBridgingEdge(), constructInterleaved(), and constructSequential().

◆ vHeapCompare

HeapCmpVertInf Avoid::MinimumTerminalSpanningTree::vHeapCompare
private

Definition at line 122 of file mtst.h.

Referenced by commitToBridgingEdge(), constructInterleaved(), and constructSequential().

◆ visitedVertices

std::list<VertInf *> Avoid::MinimumTerminalSpanningTree::visitedVertices
private

Definition at line 115 of file mtst.h.


The documentation for this class was generated from the following files: