![]() |
![]() |
![]() |
![]() |
Del.» function AddPolygon(const polygon: TPolygon; polyType: TPolyType): boolean;
C++ » bool AddPolygon(const Polygon &pg, PolyType polyType);
C# » public virtual bool AddPolygon(Polygon pg, PolyType polyType);
Any number of subject and clip polygons can be added to the clipping task, either individually via the AddPolygon() method, or as groups via the AddPolygons() method, or even using both methods.
Polygon orientation should conform with the polygon filling rule that will be applied (see Clippper's Execute method).
Polygon Coordinate range:
Polygon coordinates must be between ± 0x3FFFFFFFFFFFFFFF (± 4.6e+18), otherwise a range error will be thrown when attempting to add the polygon to the Clipper object. If coordinates can be kept between ± 0x3FFFFFFF (± 1.0e+9), a modest increase in performance (approx. 15-20%) over the larger range can be achieved by avoiding large integer math.
Return Value:
The function will return false if the polygon is empty. A polygon is empty when:
Example, Clipper.Execute, AddPolygons, Orientation, PolyFillType, Polygon, PolyType
Copyright ©2010-2013 Angus Johnson - Clipper Ver 5.1.6 - Help file built on 24-May-2013