17#include <geos/geom/Triangle.h>
18#include <geos/triangulate/tri/Tri.h>
19#include <geos/triangulate/tri/TriList.h>
20#include <geos/triangulate/quadedge/TriangleVisitor.h>
30namespace triangulate {
46 template<
typename TriType>
52 bool m_isMarked =
false;
54 bool isBoundaryTouch(TriIndex index)
const;
59 HullTri(
const Coordinate& c0,
const Coordinate& c1,
const Coordinate& c2)
61 , m_size(Triangle::longestSideLength(c0, c1, c2))
64 class HullTriCompare {
67 bool operator()(
const HullTri* a,
const HullTri* b)
69 if (a->getSize() == b->getSize())
70 return a->getArea() < b->getArea();
72 return a->getSize() < b->getSize();
77 double getSize()
const;
84 void setSizeToBoundary();
86 void setSizeToLongestEdge();
87 void setSizeToCircumradius();
90 bool isMarked()
const;
91 void setMarked(
bool marked);
93 TriIndex boundaryIndex()
const;
94 TriIndex boundaryIndexCCW()
const;
95 TriIndex boundaryIndexCW()
const;
104 bool isConnecting()
const;
111 int adjacent2VertexIndex()
const;
121 TriIndex isolatedVertexIndex(TriList<HullTri>& triList)
const;
123 double lengthOfLongestEdge()
const;
131 bool hasBoundaryTouch()
const;
133 static HullTri* findTri(TriList<HullTri>& triList, Tri* exceptTri);
134 static bool isAllMarked(TriList<HullTri>& triList);
135 static void clearMarks(TriList<HullTri>& triList);
136 static void markConnected(HullTri* triStart, HullTri* exceptTri);
137 static bool isConnected(TriList<HullTri>& triList, HullTri* exceptTri);
139 friend std::ostream& operator<<(std::ostream& os,
const HullTri& ht);
141 double lengthOfBoundary()
const;
143 void remove(TriList<HullTri>& triList);
Coordinate is the lightweight class used to store coordinates.
Definition Coordinate.h:217
Represents a planar triangle, and provides methods for calculating various properties of triangles.
Definition Triangle.h:28
Basic namespace for all GEOS functionalities.
Definition geos.h:39