Registry / other / clipper2

clipper2

JSON →
library2.0.1vcpkgunverified

Polygon Clipping and Offsetting

vcpkg install clipper2
INSTALL
IMPORT
SIG · CLIPPER2
C
clipper2
othercppv2.0.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

clipper2/clipper.h
#include <clipper2/clipper.h>

Compute the intersection of two polygons

#include <clipper2/clipper.h> #include <iostream> int main() { Clipper2Lib::Paths64 subject = {Clipper2Lib::MakePath({0, 0, 100, 0, 100, 100, 0, 100})}; Clipper2Lib::Paths64 clip = {Clipper2Lib::MakePath({50, 50, 150, 50, 150, 150, 50, 150})}; Clipper2Lib::Clipper64 clipper; clipper.AddSubject(subject); clipper.AddClip(clip); Clipper2Lib::Paths64 solution; clipper.Execute(Clipper2Lib::ClipType::Intersection, Clipper2Lib::FillRule::NonZero, solution); std::cout << "Intersection has " << solution.size() << " polygons" << std::endl; return 0; }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
2.0.1latest on vcpkg
Audit
Dependencies

No dependency data recorded yet.

Agent activity
7 hits · last 30 days
node
6
Meta
1
Resources

No resource links recorded.

clipper2 — pip install clipper2 · libregistry