Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

SchnyderLayout.h
Go to the documentation of this file.
1 
33 #pragma once
34 
35 #include <ogdf/basic/Graph.h>
36 #include <ogdf/basic/basic.h>
37 #include <ogdf/basic/geometry.h>
39 
40 namespace ogdf {
41 class GraphCopy;
42 class GridLayout;
43 template<class E>
44 class List;
45 
66 public:
68 
74  enum class CombinatorialObjects {
75  VerticesMinusDepth,
76  Faces
80  };
83 
85  CombinatorialObjects getCombinatorialObjects() { return m_combinatorialObjects; }
86 
88  void setCombinatorialObjects(CombinatorialObjects combinatorialObjects) {
89  m_combinatorialObjects = combinatorialObjects;
90  }
91 
92 protected:
93  virtual void doCall(const Graph& G, adjEntry adjExternal, GridLayout& gridLayout,
94  IPoint& boundingBox, bool fixEmbedding) override;
95 
96 private:
97  void contract(Graph& G, node a, node b, node c, List<node>& L);
98 
99  void realizer(GraphCopy& G, const List<node>& L, node a, node b, node c,
100  EdgeArray<int>& rValues, GraphCopy& T);
101 
102  void subtreeSizes(EdgeArray<int>& rValues, int i, node r, NodeArray<int>& size);
103 
104  void prefixSum(EdgeArray<int>& rValues, int i, node r, const NodeArray<int>& val,
105  NodeArray<int>& sum);
106 
107  void schnyderEmbedding(GraphCopy& GC, GridLayout& gridLayout, adjEntry adjExternal);
108 
111 };
112 
113 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
Graph.h
Includes declaration of graph class.
ogdf::GenericPoint< int >
geometry.h
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
ogdf::SchnyderLayout::m_combinatorialObjects
CombinatorialObjects m_combinatorialObjects
Determines how the barycentric coordinates of each node are computed.
Definition: SchnyderLayout.h:110
ogdf::GraphCopy
Copies of graphs supporting edge splitting.
Definition: GraphCopy.h:391
ogdf::SchnyderLayout::CombinatorialObjects
CombinatorialObjects
Each node in a Schnyder wood splits the graph into three regions.
Definition: SchnyderLayout.h:74
ogdf::AdjElement
Class for adjacency list elements.
Definition: Graph_d.h:142
ogdf::SchnyderLayout::setCombinatorialObjects
void setCombinatorialObjects(CombinatorialObjects combinatorialObjects)
Sets the type of combinatorial objects whose number corresponds to the node coordinates.
Definition: SchnyderLayout.h:88
r
int r[]
Definition: hierarchical-ranking.cpp:13
ogdf::PlanarGridLayoutModule
Base class for planar grid layout algorithms.
Definition: GridLayoutModule.h:138
ogdf::List
Doubly linked lists (maintaining the length of the list).
Definition: DfsMakeBiconnected.h:40
ogdf::internal::GraphRegisteredArray
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition: Graph_d.h:658
ogdf::Graph
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:869
basic.h
Basic declarations, included by all source files.
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
ogdf::GridLayout
Representation of a graph's grid layout.
Definition: GridLayout.h:47
ogdf::SchnyderLayout::getCombinatorialObjects
CombinatorialObjects getCombinatorialObjects()
Returns the type of combinatorial objects whose number corresponds to the node coordinates.
Definition: SchnyderLayout.h:85
ogdf::NodeElement
Class for the representation of nodes.
Definition: Graph_d.h:240
ogdf::SchnyderLayout
The class SchnyderLayout represents the layout algorithm by Schnyder [Sch90].
Definition: SchnyderLayout.h:65
ogdf::internal::EdgeArrayBase2
RegisteredArray for edges of a graph, specialized for EdgeArray<edge>.
Definition: Graph_d.h:716
GridLayoutModule.h
Declaration of interface for grid layout algorithms.