Open
Graph Drawing
Framework

 v. 2020.02 (Catalpa)
 

TutteLayout.h
Go to the documentation of this file.
1 
32 #pragma once
33 
35 #include <ogdf/basic/geometry.h>
36 #include <ogdf/external/coin.h>
37 
38 #include <coin/CoinPackedMatrix.hpp>
39 
40 namespace ogdf {
41 
43 
57 {
58 public:
59  TutteLayout();
60 
61  DRect bbox () const {
62  return m_bbox;
63  }
64 
65  void bbox (const DRect &bb) {
66  m_bbox = bb;
67  }
68 
69  virtual void call(GraphAttributes &AG) override;
70  void call(GraphAttributes &AG, const List<node> &givenNodes);
71 
72 private:
73  static bool solveLP(
74  int cols,
75  const CoinPackedMatrix &Matrix,
76  const Array<double> &rightHandSide,
77  Array<double> &x);
78 
79  void setFixedNodes(const Graph &G, List<node> &nodes,
80  List<DPoint> &pos, double radius = 1.0);
81 
87  void setFixedNodes(const Graph &G, List<node> &nodes, const List<node> &givenNodes,
88  List<DPoint> &pos, double radius = 1.0);
89 
90  bool doCall(GraphAttributes &AG,
91  const List<node> &fixedNodes,
92  List<DPoint> &fixedPositions);
93 
95 };
96 
97 }
Tutte&#39;s layout algorithm.
Definition: TutteLayout.h:56
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:492
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:99
Rectangles with real coordinates.
Definition: geometry.h:815
void bbox(const DRect &bb)
Definition: TutteLayout.h:65
Stores additional attributes of a graph (like layout information).
Doubly linked lists (maintaining the length of the list).
Definition: List.h:40
Declaration of interface for layout algorithms (class LayoutModule)
Interface of general layout algorithms.
Definition: LayoutModule.h:44
Definition of ogdf::CoinManager.
The namespace for all OGDF objects.
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment, DPolygon, DRect, DIntersectableRect.
DRect bbox() const
Definition: TutteLayout.h:61