Open
Graph Drawing
Framework

 v. 2020.02 (Catalpa)
 

EmbedderOptimalFlexDraw.h
Go to the documentation of this file.
1 
32 #pragma once
33 
35 #include <memory>
38 
39 namespace ogdf {
40 
42 
49 {
50 public:
52 
53  virtual void doCall(Graph &G, adjEntry &adjExternal) override;
54 
56  void setMinCostFlowComputer(MinCostFlowModule<int> *pMinCostFlowComputer) {
57  m_minCostFlowComputer.reset(pMinCostFlowComputer);
58  }
59 
61  void cost(EdgeArray<int> *cost) {
62  m_cost = cost;
63  }
64 
65 private:
66 
67  std::unique_ptr<MinCostFlowModule<int>> m_minCostFlowComputer;
68 
70 
71  void createNetwork(
72  node parent,
73  node mu,
74  int bends,
75  NodeArray<int> cost[],
76  Skeleton &skeleton,
77  EdgeArray<node> &edgeNode,
78  Graph &N,
79  EdgeArray<int> &upper,
80  EdgeArray<int> &perUnitCost,
81  NodeArray<int> &supply);
82 
83  void optimizeOverEmbeddings(
85  node parent,
86  node mu,
87  int bends,
88  NodeArray<int> cost[],
89  NodeArray<long long> embedding[]);
90 
91  void computePrincipalSplitComponentCost(
93  NodeArray<int> cost[],
94  NodeArray<long long> embedding[],
95  node parent,
96  node mu);
97 };
98 
99 }
The algorithm computes a planar embedding with minimum cost.
void cost(EdgeArray< int > *cost)
Sets bend costs for each edge.
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:492
void setMinCostFlowComputer(MinCostFlowModule< int > *pMinCostFlowComputer)
Sets the module option to compute min-cost flow.
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:99
std::unique_ptr< MinCostFlowModule< int > > m_minCostFlowComputer
Interface for min-cost flow algorithms.
Defines ogdf::EmbedderModule.
Skeleton graphs of nodes in an SPQR-tree.
Definition: Skeleton.h:61
Declaration of class StaticPlanarSPQRTree.
Definition of ogdf::MinCostFlowModule class template.
Class for the representation of nodes.
Definition: Graph_d.h:169
The namespace for all OGDF objects.
Base class for embedder algorithms.
SPQR-trees of planar graphs.
Class for adjacency list elements.
Definition: Graph_d.h:79