Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
SolarMerger.h
Go to the documentation of this file.
1
32#pragma once
33
35
36namespace ogdf {
37
39
43 struct PathData {
44 explicit PathData(int targetSunParam = 0, double len = 0.0f, int num = 0)
45 : targetSun(targetSunParam), length(len), number(num) { }
46
48 double length;
49 int number;
50 };
51
56 NodeArray<int> m_celestial; // 0 = unknown, 1 = sun, 2 = planet, 3 = moon
60 std::map<int, std::map<int, PathData>> m_interSystemPaths;
61
62 node sunOf(node object);
64 void addPath(node sourceSun, node targetSun, double distance);
69 std::vector<node> selectSuns(MultilevelGraph& MLG);
70
71public:
72 explicit SolarMerger(bool simple = false, bool massAsNodeRadius = false);
73
75};
76
77}
Declaration of MultilevelBuilder.
Data type for general directed graphs (adjacency list representation).
Definition Graph_d.h:521
Base class for merger modules.
Dynamic arrays indexed with nodes.
Definition NodeArray.h:125
Class for the representation of nodes.
Definition Graph_d.h:177
The solar merger for multilevel layout.
Definition SolarMerger.h:42
bool collapseSolarSystem(MultilevelGraph &MLG, node sun, int level)
std::vector< node > selectSuns(MultilevelGraph &MLG)
int calcSystemMass(node v)
NodeArray< std::vector< PathData > > m_pathDistances
Definition SolarMerger.h:59
double distanceToSun(node object, MultilevelGraph &MLG)
void addPath(node sourceSun, node targetSun, double distance)
void findInterSystemPaths(Graph &G, MultilevelGraph &MLG)
bool buildOneLevel(MultilevelGraph &MLG) override
This method constructs one more level on top of an existing MultilevelGraph.
NodeArray< int > m_celestial
Definition SolarMerger.h:56
SolarMerger(bool simple=false, bool massAsNodeRadius=false)
std::map< int, std::map< int, PathData > > m_interSystemPaths
Definition SolarMerger.h:60
void buildAllLevels(MultilevelGraph &MLG) override
NodeArray< node > m_orbitalCenter
Definition SolarMerger.h:57
NodeArray< unsigned int > m_mass
Definition SolarMerger.h:54
NodeArray< double > m_distanceToOrbit
Definition SolarMerger.h:58
node sunOf(node object)
NodeArray< double > m_radius
Definition SolarMerger.h:55
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition config.h:101
static MultilevelBuilder * getDoubleFactoredZeroAdjustedMerger()
The namespace for all OGDF objects.
PathData(int targetSunParam=0, double len=0.0f, int num=0)
Definition SolarMerger.h:44