Open
Graph Drawing
Framework
v. 2023.09 (Elderberry)
Overview
Class Hierarchy
Class Index
Class List
Members
Namespaces
Source Files
ConvexHull.h
Go to the documentation of this file.
1
32
#pragma once
33
34
#include <
ogdf/basic/basic.h
>
35
#include <
ogdf/basic/geometry.h
>
36
37
#include <vector>
38
39
namespace
ogdf
{
40
class
GraphAttributes;
41
class
MultilevelGraph;
42
44
49
class
OGDF_EXPORT
ConvexHull
{
50
private
:
51
bool
sameDirection(
const
DPoint
& start,
const
DPoint
&
end
,
const
DPoint
& s,
const
DPoint
& e)
const
;
52
53
// calculates a convex hull very quickly but only works with cross-free Polygons!
54
DPolygon
conv(
const
DPolygon
& poly)
const
;
55
56
// Calculates the Part of the convex hull that is left of line start-end
57
// /a points should only contain points that really are left of the line.
58
void
leftHull(std::vector<DPoint> points,
DPoint
& start,
DPoint
&
end
,
DPolygon
& hullPoly)
const
;
59
60
61
public
:
62
ConvexHull
();
63
~
ConvexHull
();
64
65
DPoint
calcNormal(
const
DPoint
& start,
const
DPoint
&
end
)
const
;
66
double
leftOfLine(
const
DPoint
& normal,
const
DPoint
& point,
const
DPoint
& pointOnLine)
const
;
67
68
DPolygon
call(std::vector<DPoint> points)
const
;
69
DPolygon
call(
GraphAttributes
& GA)
const
;
70
DPolygon
call(
MultilevelGraph
& MLG)
const
;
71
};
72
73
}
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
ogdf::GenericPoint< double >
geometry.h
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
ogdf::ConvexHull
Computes the convex hull of a set of points or a layout.
Definition:
ConvexHull.h:49
ogdf::DPolygon
Polygons with real coordinates.
Definition:
geometry.h:989
ogdf::MultilevelGraph
Definition:
MultilevelGraph.h:69
basic.h
Basic declarations, included by all source files.
ogdf::end
HypergraphRegistry< HypernodeElement >::iterator end(const HypergraphRegistry< HypernodeElement > &self)
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition:
config.h:101
include
ogdf
graphalg
ConvexHull.h
This site is powered by Netlify.
© 1999–2024
The OGDF Team