Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

TutteLayout.h
Go to the documentation of this file.
1 
32 #pragma once
33 
34 #include <ogdf/basic/Array.h>
35 #include <ogdf/basic/Graph.h>
37 #include <ogdf/basic/basic.h>
38 #include <ogdf/basic/geometry.h>
39 
40 #include <ogdf/external/coin.h>
41 
42 class CoinPackedMatrix;
43 
44 namespace ogdf {
45 class GraphAttributes;
46 template<class E>
47 class List;
48 
50 
64 public:
65  TutteLayout();
66 
67  DRect bbox() const { return m_bbox; }
68 
69  void bbox(const DRect& bb) { m_bbox = bb; }
70 
71  virtual void call(GraphAttributes& AG) override;
72  void call(GraphAttributes& AG, const List<node>& givenNodes);
73 
74 private:
75  static bool solveLP(int cols, const CoinPackedMatrix& Matrix,
76  const Array<double>& rightHandSide, Array<double>& x);
77 
78  void setFixedNodes(const Graph& G, List<node>& nodes, List<DPoint>& pos, double radius = 1.0);
79 
85  void setFixedNodes(const Graph& G, List<node>& nodes, const List<node>& givenNodes,
86  List<DPoint>& pos, double radius = 1.0);
87 
88  bool doCall(GraphAttributes& AG, const List<node>& fixedNodes, List<DPoint>& fixedPositions);
89 
91 };
92 
93 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
ogdf::GraphAttributes
Stores additional attributes of a graph (like layout information).
Definition: GraphAttributes.h:72
Graph.h
Includes declaration of graph class.
ogdf::TutteLayout
Tutte's layout algorithm.
Definition: TutteLayout.h:63
geometry.h
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
LayoutModule.h
Declaration of interface for layout algorithms (class LayoutModule)
ogdf::TutteLayout::m_bbox
DRect m_bbox
Definition: TutteLayout.h:90
coin.h
Definition of ogdf::CoinManager.
ogdf::Array< double >
ogdf::DRect
Rectangles with real coordinates.
Definition: geometry.h:798
ogdf::List
Doubly linked lists (maintaining the length of the list).
Definition: DfsMakeBiconnected.h:40
ogdf::Graph
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:869
ogdf::TutteLayout::bbox
DRect bbox() const
Definition: TutteLayout.h:67
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
Array.h
Declaration and implementation of Array class and Array algorithms.
ogdf::TutteLayout::bbox
void bbox(const DRect &bb)
Definition: TutteLayout.h:69
ogdf::LayoutModule
Interface of general layout algorithms.
Definition: LayoutModule.h:45