Classes | |
class Clipper | |
class ClipperBase | |
class clipperException | |
class ClipperOffset | |
struct DoublePoint | |
class Int128 | |
struct IntersectNode | |
struct IntPoint | |
struct IntRect | |
struct Join | |
struct LocalMinimum | |
struct LocMinSorter | |
struct OutPt | |
struct OutRec | |
class PolyNode | |
class PolyTree | |
struct TEdge | |
Typedefs | |
typedef signed long long cInt | |
typedef std::vector< TEdge * > EdgeList | |
typedef std::vector< IntersectNode * > IntersectList | |
typedef std::vector< Join * > JoinList | |
typedef signed long long long64 | |
typedef std::vector< IntPoint > Path | |
typedef std::vector< Path > Paths | |
typedef std::vector< PolyNode * > PolyNodes | |
typedef std::vector< OutRec * > PolyOutList | |
typedef unsigned long long ulong64 | |
Enumerations | |
enum ClipType { ctIntersection, ctUnion, ctDifference, ctXor } | |
enum Direction { dRightToLeft, dLeftToRight } | |
enum EdgeSide { esLeft = 1, esRight = 2 } | |
enum EndType { etClosedPolygon, etClosedLine, etOpenButt, etOpenSquare, etOpenRound } | |
enum InitOptions { ioReverseSolution = 1, ioStrictlySimple = 2, ioPreserveCollinear = 4 } | |
enum JoinType { jtSquare, jtRound, jtMiter } | |
enum NodeType { ntAny, ntOpen, ntClosed } | |
enum PolyFillType { pftEvenOdd, pftNonZero, pftPositive, pftNegative } | |
enum PolyType { ptSubject, ptClip } | |
Functions | |
cInt Abs (cInt val) | |
void AddPolyNodeToPaths (const PolyNode &polynode, NodeType nodetype, Paths &paths) | |
double Area (const OutRec &outRec) | |
double Area (const Path &poly) | |
void CleanPolygon (const Path &in_poly, Path &out_poly, double distance) | |
void CleanPolygon (Path &poly, double distance) | |
void CleanPolygons (const Paths &in_polys, Paths &out_polys, double distance) | |
void CleanPolygons (Paths &polys, double distance) | |
void ClosedPathsFromPolyTree (const PolyTree &polytree, Paths &paths) | |
void DisposeOutPts (OutPt *&pp) | |
double DistanceFromLineSqrd (const IntPoint &pt, const IntPoint &ln1, const IntPoint &ln2) | |
double DistanceSqrd (const IntPoint &pt1, const IntPoint &pt2) | |
OutPt * DupOutPt (OutPt *outPt, bool InsertAfter) | |
bool E2InsertsBeforeE1 (TEdge &e1, TEdge &e2) | |
bool EdgesAdjacent (const IntersectNode &inode) | |
OutPt * ExcludeOp (OutPt *op) | |
TEdge * FindNextLocMin (TEdge *E) | |
bool FirstIsBottomPt (const OutPt *btmPt1, const OutPt *btmPt2) | |
OutPt * GetBottomPt (OutPt *pp) | |
double GetDx (const IntPoint pt1, const IntPoint pt2) | |
void GetHorzDirection (TEdge &HorzEdge, Direction &Dir, cInt &Left, cInt &Right) | |
OutRec * GetLowermostRec (OutRec *outRec1, OutRec *outRec2) | |
TEdge * GetMaximaPair (TEdge *e) | |
TEdge * GetNextInAEL (TEdge *e, Direction dir) | |
bool GetOverlap (const cInt a1, const cInt a2, const cInt b1, const cInt b2, cInt &Left, cInt &Right) | |
bool GetOverlapSegment (IntPoint pt1a, IntPoint pt1b, IntPoint pt2a, IntPoint pt2b, IntPoint &pt1, IntPoint &pt2) | |
DoublePoint GetUnitNormal (const IntPoint &pt1, const IntPoint &pt2) | |
bool HorzSegmentsOverlap (cInt seg1a, cInt seg1b, cInt seg2a, cInt seg2b) | |
void InitEdge (TEdge *e, TEdge *eNext, TEdge *ePrev, const IntPoint &Pt) | |
void InitEdge2 (TEdge &e, PolyType Pt) | |
Int128 Int128Mul (long64 lhs, long64 rhs) | |
bool IntersectListSort (IntersectNode *node1, IntersectNode *node2) | |
void IntersectPoint (TEdge &Edge1, TEdge &Edge2, IntPoint &ip) | |
bool IsHorizontal (TEdge &e) | |
bool IsIntermediate (TEdge *e, const cInt Y) | |
bool IsMaxima (TEdge *e, const cInt Y) | |
bool IsMinima (TEdge *e) | |
bool JoinHorz (OutPt *op1, OutPt *op1b, OutPt *op2, OutPt *op2b, const IntPoint Pt, bool DiscardLeft) | |
void Minkowski (const Path &poly, const Path &path, Paths &solution, bool isSum, bool isClosed) | |
void MinkowskiDiff (const Path &poly1, const Path &poly2, Paths &solution) | |
void MinkowskiSum (const Path &pattern, const Path &path, Paths &solution, bool pathIsClosed) | |
void MinkowskiSum (const Path &pattern, const Paths &paths, Paths &solution, bool pathIsClosed) | |
void OpenPathsFromPolyTree (PolyTree &polytree, Paths &paths) | |
Path & operator<< (Path &poly, const IntPoint &p) | |
Paths & operator<< (Paths &polys, const Path &p) | |
std::ostream & operator<< (std::ostream &s, const IntPoint &p) | |
std::ostream & operator<< (std::ostream &s, const Path &p) | |
std::ostream & operator<< (std::ostream &s, const Paths &p) | |
bool Orientation (const Path &poly) | |
bool Param1RightOfParam2 (OutRec *outRec1, OutRec *outRec2) | |
static OutRec * ParseFirstLeft (OutRec *FirstLeft) | |
int PointCount (OutPt *Pts) | |
int PointInPolygon (const IntPoint &pt, const Path &path) | |
int PointInPolygon (const IntPoint &pt, OutPt *op) | |
bool PointIsVertex (const IntPoint &Pt, OutPt *pp) | |
bool PointsAreClose (IntPoint pt1, IntPoint pt2, double distSqrd) | |
bool Poly2ContainsPoly1 (OutPt *OutPt1, OutPt *OutPt2) | |
void PolyTreeToPaths (const PolyTree &polytree, Paths &paths) | |
bool Pt2IsBetweenPt1AndPt3 (const IntPoint pt1, const IntPoint pt2, const IntPoint pt3) | |
void RangeTest (const IntPoint &Pt, bool &useFullRange) | |
TEdge * RemoveEdge (TEdge *e) | |
void ReverseHorizontal (TEdge &e) | |
void ReversePath (Path &p) | |
void ReversePaths (Paths &p) | |
void ReversePolyPtLinks (OutPt *pp) | |
cInt Round (double val) | |
void SetDx (TEdge &e) | |
void SimplifyPolygon (const Path &in_poly, Paths &out_polys, PolyFillType fillType) | |
void SimplifyPolygons (const Paths &in_polys, Paths &out_polys, PolyFillType fillType) | |
void SimplifyPolygons (Paths &polys, PolyFillType fillType) | |
bool SlopesEqual (const IntPoint pt1, const IntPoint pt2, const IntPoint pt3, bool UseFullInt64Range) | |
bool SlopesEqual (const IntPoint pt1, const IntPoint pt2, const IntPoint pt3, const IntPoint pt4, bool UseFullInt64Range) | |
bool SlopesEqual (const TEdge &e1, const TEdge &e2, bool UseFullInt64Range) | |
bool SlopesNearCollinear (const IntPoint &pt1, const IntPoint &pt2, const IntPoint &pt3, double distSqrd) | |
void Swap (cInt &val1, cInt &val2) | |
void SwapIntersectNodes (IntersectNode &int1, IntersectNode &int2) | |
void SwapPoints (IntPoint &pt1, IntPoint &pt2) | |
void SwapPolyIndexes (TEdge &Edge1, TEdge &Edge2) | |
void SwapSides (TEdge &Edge1, TEdge &Edge2) | |
cInt TopX (TEdge &edge, const cInt currentY) | |
void TranslatePath (const Path &input, Path &output, IntPoint delta) | |
void UpdateOutPtIdxs (OutRec &outrec) | |
Variables | |
static const double def_arc_tolerance = 0.25 | |
static const cInt hiRange = 0x3FFFFFFFFFFFFFFFLL | |
static const cInt loRange = 0x3FFFFFFF | |
static const double pi = 3.141592653589793238 | |
static const int Skip = -2 | |
static const double two_pi = pi *2 | |
static const int Unassigned = -1 | |
Typedef Documentation
◆ cInt
typedef signed long long ClipperLib::cInt |
◆ EdgeList
typedef std::vector< TEdge* > ClipperLib::EdgeList |
◆ IntersectList
typedef std::vector< IntersectNode* > ClipperLib::IntersectList |
◆ JoinList
typedef std::vector< Join* > ClipperLib::JoinList |
◆ long64
typedef signed long long ClipperLib::long64 |
◆ Path
typedef std::vector< IntPoint > ClipperLib::Path |
◆ Paths
typedef std::vector< Path > ClipperLib::Paths |
◆ PolyNodes
typedef std::vector< PolyNode* > ClipperLib::PolyNodes |
◆ PolyOutList
typedef std::vector< OutRec* > ClipperLib::PolyOutList |
◆ ulong64
typedef unsigned long long ClipperLib::ulong64 |
Enumeration Type Documentation
◆ ClipType
enum ClipperLib::ClipType |
◆ Direction
◆ EdgeSide
enum ClipperLib::EdgeSide |
◆ EndType
enum ClipperLib::EndType |
◆ InitOptions
◆ JoinType
enum ClipperLib::JoinType |
◆ NodeType
enum ClipperLib::NodeType |
◆ PolyFillType
◆ PolyType
enum ClipperLib::PolyType |
Function Documentation
◆ Abs()
◆ AddPolyNodeToPaths()
◆ Area() [1/2]
double ClipperLib::Area | ( | const OutRec & | outRec | ) |
References ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
◆ Area() [2/2]
double ClipperLib::Area | ( | const Path & | poly | ) |
Referenced by ParseFirstLeft().
◆ CleanPolygon() [1/2]
Referenced by AdaptivePath::CleanPath().
◆ CleanPolygon() [2/2]
void ClipperLib::CleanPolygon | ( | Path & | poly, |
double | distance | ||
) |
◆ CleanPolygons() [1/2]
Referenced by AdaptivePath::ClearedArea::ExpandCleared().
◆ CleanPolygons() [2/2]
void ClipperLib::CleanPolygons | ( | Paths & | polys, |
double | distance | ||
) |
◆ ClosedPathsFromPolyTree()
Referenced by CArea::Clip().
◆ DisposeOutPts()
void ClipperLib::DisposeOutPts | ( | OutPt *& | pp | ) |
References RemoveEdge().
◆ DistanceFromLineSqrd()
double ClipperLib::DistanceFromLineSqrd | ( | const IntPoint & | pt, |
const IntPoint & | ln1, | ||
const IntPoint & | ln2 | ||
) |
Referenced by SimplifyPolygons().
◆ DistanceSqrd()
◆ DupOutPt()
References ClipperLib::OutPt::Pt.
◆ E2InsertsBeforeE1()
◆ EdgesAdjacent()
bool ClipperLib::EdgesAdjacent | ( | const IntersectNode & | inode | ) |
◆ ExcludeOp()
◆ FindNextLocMin()
References IsHorizontal().
◆ FirstIsBottomPt()
◆ GetBottomPt()
References Pt2IsBetweenPt1AndPt3(), ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
◆ GetDx()
References Round().
Referenced by GetOverlapSegment(), and SwapPoints().
◆ GetHorzDirection()
◆ GetLowermostRec()
Referenced by ParseFirstLeft().
◆ GetMaximaPair()
Referenced by IntersectListSort().
◆ GetNextInAEL()
◆ GetOverlap()
bool ClipperLib::GetOverlap | ( | const cInt | a1, |
const cInt | a2, | ||
const cInt | b1, | ||
const cInt | b2, | ||
cInt & | Left, | ||
cInt & | Right | ||
) |
◆ GetOverlapSegment()
bool ClipperLib::GetOverlapSegment | ( | IntPoint | pt1a, |
IntPoint | pt1b, | ||
IntPoint | pt2a, | ||
IntPoint | pt2b, | ||
IntPoint & | pt1, | ||
IntPoint & | pt2 | ||
) |
References GetDx().
◆ GetUnitNormal()
DoublePoint ClipperLib::GetUnitNormal | ( | const IntPoint & | pt1, |
const IntPoint & | pt2 | ||
) |
◆ HorzSegmentsOverlap()
References RangeTest().
◆ InitEdge()
References ReverseHorizontal(), and Swap().
◆ InitEdge2()
Referenced by ReversePolyPtLinks().
◆ Int128Mul()
Referenced by ClipperLib::Int128::operator-=(), and Poly2ContainsPoly1().
◆ IntersectListSort()
bool ClipperLib::IntersectListSort | ( | IntersectNode * | node1, |
IntersectNode * | node2 | ||
) |
References GetMaximaPair().
◆ IntersectPoint()
◆ IsHorizontal()
Referenced by ClipperLib::ClipperBase::ClipperBase(), FindNextLocMin(), RangeTest(), and SwapSides().
◆ IsIntermediate()
◆ IsMaxima()
◆ IsMinima()
◆ JoinHorz()
bool ClipperLib::JoinHorz | ( | OutPt * | op1, |
OutPt * | op1b, | ||
OutPt * | op2, | ||
OutPt * | op2b, | ||
const IntPoint | Pt, | ||
bool | DiscardLeft | ||
) |
◆ Minkowski()
void ClipperLib::Minkowski | ( | const Path & | poly, |
const Path & | path, | ||
Paths & | solution, | ||
bool | isSum, | ||
bool | isClosed | ||
) |
Referenced by MinkowskiSum().
◆ MinkowskiDiff()
◆ MinkowskiSum() [1/2]
void ClipperLib::MinkowskiSum | ( | const Path & | pattern, |
const Path & | path, | ||
Paths & | solution, | ||
bool | pathIsClosed | ||
) |
References ClipperLib::ClipperBase::AddPaths(), ctUnion, Minkowski(), pftNonZero, and ptSubject.
◆ MinkowskiSum() [2/2]
void ClipperLib::MinkowskiSum | ( | const Path & | pattern, |
const Paths & | paths, | ||
Paths & | solution, | ||
bool | pathIsClosed | ||
) |
◆ OpenPathsFromPolyTree()
Referenced by CArea::Clip().
◆ operator<<() [1/5]
◆ operator<<() [2/5]
◆ operator<<() [3/5]
std::ostream & ClipperLib::operator<< | ( | std::ostream & | s, |
const IntPoint & | p | ||
) |
◆ operator<<() [4/5]
std::ostream & ClipperLib::operator<< | ( | std::ostream & | s, |
const Path & | p | ||
) |
◆ operator<<() [5/5]
std::ostream & ClipperLib::operator<< | ( | std::ostream & | s, |
const Paths & | p | ||
) |
◆ Orientation()
References ClipperLib::OutPt::Next, and ClipperLib::OutPt::Pt.
◆ Param1RightOfParam2()
References esLeft, ClipperLib::OutPt::Next, ClipperLib::OutPt::Prev, and ReversePolyPtLinks().
Referenced by ParseFirstLeft().
◆ ParseFirstLeft()
References Area(), GetLowermostRec(), Param1RightOfParam2(), Poly2ContainsPoly1(), ReversePolyPtLinks(), and UpdateOutPtIdxs().
◆ PointCount()
int ClipperLib::PointCount | ( | OutPt * | Pts | ) |
◆ PointInPolygon() [1/2]
◆ PointInPolygon() [2/2]
◆ PointIsVertex()
References ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
◆ PointsAreClose()
◆ Poly2ContainsPoly1()
References Int128Mul(), SlopesEqual(), ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
Referenced by ParseFirstLeft().
◆ PolyTreeToPaths()
◆ Pt2IsBetweenPt1AndPt3()
bool ClipperLib::Pt2IsBetweenPt1AndPt3 | ( | const IntPoint | pt1, |
const IntPoint | pt2, | ||
const IntPoint | pt3 | ||
) |
References RangeTest(), ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
Referenced by GetBottomPt().
◆ RangeTest()
References IsHorizontal().
Referenced by HorzSegmentsOverlap(), and Pt2IsBetweenPt1AndPt3().
◆ RemoveEdge()
References SwapPoints().
Referenced by DisposeOutPts().
◆ ReverseHorizontal()
void ClipperLib::ReverseHorizontal | ( | TEdge & | e | ) |
Referenced by InitEdge().
◆ ReversePath()
void ClipperLib::ReversePath | ( | Path & | p | ) |
References ClipperLib::IntPoint::X, and ClipperLib::IntPoint::Y.
Referenced by AdaptivePath::ConnectPaths().
◆ ReversePaths()
void ClipperLib::ReversePaths | ( | Paths & | p | ) |
Referenced by AdaptivePath::Adaptive2d::Execute().
◆ ReversePolyPtLinks()
void ClipperLib::ReversePolyPtLinks | ( | OutPt * | pp | ) |
References InitEdge2(), and SetDx().
Referenced by Param1RightOfParam2(), and ParseFirstLeft().
◆ Round()
cInt ClipperLib::Round | ( | double | val | ) |
Referenced by GetDx(), IntersectPoint(), SwapPolyIndexes(), and TopX().
◆ SetDx()
void ClipperLib::SetDx | ( | TEdge & | e | ) |
References TopX().
Referenced by ReversePolyPtLinks(), and SlopesEqual().
◆ SimplifyPolygon()
void ClipperLib::SimplifyPolygon | ( | const Path & | in_poly, |
Paths & | out_polys, | ||
PolyFillType | fillType | ||
) |
◆ SimplifyPolygons() [1/2]
void ClipperLib::SimplifyPolygons | ( | const Paths & | in_polys, |
Paths & | out_polys, | ||
PolyFillType | fillType | ||
) |
Referenced by AdaptivePath::Adaptive2d::Execute().
◆ SimplifyPolygons() [2/2]
void ClipperLib::SimplifyPolygons | ( | Paths & | polys, |
PolyFillType | fillType | ||
) |
References DistanceFromLineSqrd().
◆ SlopesEqual() [1/3]
bool ClipperLib::SlopesEqual | ( | const IntPoint | pt1, |
const IntPoint | pt2, | ||
const IntPoint | pt3, | ||
bool | UseFullInt64Range | ||
) |
References SetDx().
◆ SlopesEqual() [2/3]
bool ClipperLib::SlopesEqual | ( | const IntPoint | pt1, |
const IntPoint | pt2, | ||
const IntPoint | pt3, | ||
const IntPoint | pt4, | ||
bool | UseFullInt64Range | ||
) |
◆ SlopesEqual() [3/3]
Referenced by Poly2ContainsPoly1().
◆ SlopesNearCollinear()
bool ClipperLib::SlopesNearCollinear | ( | const IntPoint & | pt1, |
const IntPoint & | pt2, | ||
const IntPoint & | pt3, | ||
double | distSqrd | ||
) |
References ClipperLib::OutPt::Idx, ClipperLib::OutPt::Next, and ClipperLib::OutPt::Prev.
◆ Swap()
Referenced by InitEdge().
◆ SwapIntersectNodes()
void ClipperLib::SwapIntersectNodes | ( | IntersectNode & | int1, |
IntersectNode & | int2 | ||
) |
◆ SwapPoints()
References GetDx().
Referenced by RemoveEdge().
◆ SwapPolyIndexes()
◆ SwapSides()
References IsHorizontal().
◆ TopX()
◆ TranslatePath()
References ntAny, ntClosed, and ntOpen.
Referenced by AdaptivePath::Adaptive2d::Execute().
◆ UpdateOutPtIdxs()
void ClipperLib::UpdateOutPtIdxs | ( | OutRec & | outrec | ) |
Referenced by ParseFirstLeft().
Variable Documentation
◆ def_arc_tolerance
|
static |
◆ hiRange
|
static |
◆ loRange
|
static |
◆ pi
|
static |
◆ Skip
|
static |
◆ two_pi
|
static |
◆ Unassigned
|
static |
Referenced by ClipperLib::ClipperBase::AddPaths(), and ClipperLib::ClipperBase::Clear().