#include "polypartition.h"
#include <math.h>
#include <string.h>
#include <algorithm>
TPPLPoly::TPPLPoly() { … }
TPPLPoly::~TPPLPoly() { … }
void TPPLPoly::Clear() { … }
void TPPLPoly::Init(long numpoints) { … }
void TPPLPoly::Triangle(TPPLPoint &p1, TPPLPoint &p2, TPPLPoint &p3) { … }
TPPLPoly::TPPLPoly(const TPPLPoly &src) : … { … }
TPPLPoly &TPPLPoly::operator=(const TPPLPoly &src) { … }
TPPLOrientation TPPLPoly::GetOrientation() const { … }
void TPPLPoly::SetOrientation(TPPLOrientation orientation) { … }
void TPPLPoly::Invert() { … }
TPPLPartition::PartitionVertex::PartitionVertex() : … { … }
TPPLPoint TPPLPartition::Normalize(const TPPLPoint &p) { … }
tppl_float TPPLPartition::Distance(const TPPLPoint &p1, const TPPLPoint &p2) { … }
int TPPLPartition::Intersects(TPPLPoint &p11, TPPLPoint &p12, TPPLPoint &p21, TPPLPoint &p22) { … }
int TPPLPartition::RemoveHoles(TPPLPolyList *inpolys, TPPLPolyList *outpolys) { … }
bool TPPLPartition::IsConvex(TPPLPoint &p1, TPPLPoint &p2, TPPLPoint &p3) { … }
bool TPPLPartition::IsReflex(TPPLPoint &p1, TPPLPoint &p2, TPPLPoint &p3) { … }
bool TPPLPartition::IsInside(TPPLPoint &p1, TPPLPoint &p2, TPPLPoint &p3, TPPLPoint &p) { … }
bool TPPLPartition::InCone(TPPLPoint &p1, TPPLPoint &p2, TPPLPoint &p3, TPPLPoint &p) { … }
bool TPPLPartition::InCone(PartitionVertex *v, TPPLPoint &p) { … }
void TPPLPartition::UpdateVertexReflexity(PartitionVertex *v) { … }
void TPPLPartition::UpdateVertex(PartitionVertex *v, PartitionVertex *vertices, long numvertices) { … }
int TPPLPartition::Triangulate_EC(TPPLPoly *poly, TPPLPolyList *triangles) { … }
int TPPLPartition::Triangulate_EC(TPPLPolyList *inpolys, TPPLPolyList *triangles) { … }
int TPPLPartition::ConvexPartition_HM(TPPLPoly *poly, TPPLPolyList *parts) { … }
int TPPLPartition::ConvexPartition_HM(TPPLPolyList *inpolys, TPPLPolyList *parts) { … }
int TPPLPartition::Triangulate_OPT(TPPLPoly *poly, TPPLPolyList *triangles) { … }
void TPPLPartition::UpdateState(long a, long b, long w, long i, long j, DPState2 **dpstates) { … }
void TPPLPartition::TypeA(long i, long j, long k, PartitionVertex *vertices, DPState2 **dpstates) { … }
void TPPLPartition::TypeB(long i, long j, long k, PartitionVertex *vertices, DPState2 **dpstates) { … }
int TPPLPartition::ConvexPartition_OPT(TPPLPoly *poly, TPPLPolyList *parts) { … }
int TPPLPartition::MonotonePartition(TPPLPolyList *inpolys, TPPLPolyList *monotonePolys) { … }
void TPPLPartition::AddDiagonal(MonotoneVertex *vertices, long *numvertices, long index1, long index2,
TPPLVertexType *vertextypes, RBSet<ScanLineEdge>::Element **edgeTreeIterators,
RBSet<ScanLineEdge> *edgeTree, long *helpers) { … }
bool TPPLPartition::Below(TPPLPoint &p1, TPPLPoint &p2) { … }
bool TPPLPartition::VertexSorter::operator()(long index1, long index2) { … }
bool TPPLPartition::ScanLineEdge::IsConvex(const TPPLPoint &p1, const TPPLPoint &p2, const TPPLPoint &p3) const { … }
bool TPPLPartition::ScanLineEdge::operator<(const ScanLineEdge &other) const { … }
int TPPLPartition::TriangulateMonotone(TPPLPoly *inPoly, TPPLPolyList *triangles) { … }
int TPPLPartition::Triangulate_MONO(TPPLPolyList *inpolys, TPPLPolyList *triangles) { … }
int TPPLPartition::Triangulate_MONO(TPPLPoly *poly, TPPLPolyList *triangles) { … }