--- id: pyclipper version: "1.4.0" license: MIT license_treatment: permissive maintenance: aging --- # pyclipper — Cython wrapper for the C++ translation of the Angus Johnson's Clipper library (ver. 6.4.2) License: permissive · Maintenance: aging · Downloads: 11.8M/mo ## What it is and what it does Pyclipper is a Cython wrapper around Angus Johnson's Clipper library (version 6.4.2), a C++ polygon clipping and offsetting engine. It exposes the core clipping operations—intersection, union, difference, and exclusive-or—as well as polygon offsetting, using Vatti's clipping algorithm for numerical robustness. The library works with integer coordinates internally to avoid floating-point precision issues; helper functions scale_to_clipper() and scale_from_clipper() are provided to convert between floating-point and integer representations. The package is designed for developers working with computational geometry, graphics, or CAD-like applications. It has no runtime dependencies beyond Python itself. The API closely mirrors the original C++ library's naming conventions, with classes Pyclipper and PyclipperOffset replacing the C++ Clipper and ClipperOffset. Since version 1.0.0, automatic scaling via SCALING_FACTOR was removed to preserve the original library's numerical robustness, which is a breaking change from earlier versions. Use it for: - Compute intersections, unions, or differences of polygon regions in graphics or GIS applications. - Offset polygon boundaries inward or outward by a fixed distance for buffer operations. - Perform boolean operations on closed polygons in CAD or design software. - Combine multiple polygon paths with clipping rules (even-odd or non-zero winding) in computational geometry. - Scale and clip line segments or polygons while maintaining numerical precision in scientific applications. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Pyclipper performs polygon clipping operations (intersection, union, difference, exclusive-or) and polygon offsetting using a Cython wrapper around the C++ Clipper library version 6.4.2. Yes, if you need robust polygon clipping or offsetting. The package is stable, has no known vulnerabilities, supports current Python versions (3.10–3.14), and is widely downloaded (11.7M monthly). The aging maintenance status (256 days since release) is a minor concern but not a blocker; the repository is active and the underlying algorithm is mature. Install friction is moderate due to compilation, but prebuilt wheels are available for common platforms. Breaking changes in version 1.0.0 (SCALING_FACTOR removal) may affect legacy code, so review migration notes if upgrading from 0.9.3b0. ## Install pip install pyclipper uv add pyclipper poetry add pyclipper ## Installing pyclipper Before you install: Medium install friction due to compiled C++ extension; however, prebuilt wheels are available for Python 3.10–3.14 across Windows, macOS, and Linux platforms. Package is aging (256 days since last release) but repository remains active with 261 stars and no archived status. License in practice: MIT license (permissive); the underlying Clipper library is Boost Software License (freeware for open source and commercial use). No licensing restrictions on your use of pyclipper. Quickstart: pip install pyclipper import pyclipper pc = pyclipper.Pyclipper() pc.AddPath(((190, 210), (240, 210), (240, 130), (190, 130)), pyclipper.PT_CLIP, True) pc.AddPaths((((180, 200), (260, 200), (260, 150), (180, 150)),), pyclipper.PT_SUBJECT, True) solution = pc.Execute(pyclipper.CT_INTERSECTION, pyclipper.PFT_EVENODD, pyclipper.PFT_EVENODD) Requires Python 3.10 or later; compiled extension may require build tools if installing from source rather than a prebuilt wheel. Verify before relying: - Whether the package is actively maintained going forward (last release 256 days ago, status marked 'aging'). - Performance characteristics and scalability limits for large polygon datasets or complex clipping operations. - Availability of documentation beyond the README and GitHub wiki. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: medium - Maintenance: aging - Downloads: 11.8M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags polygon clipping intersection union, polygon boolean operations, polygon offsetting, vatti clipping algorithm, line polygon clipping, geometric polygon operations, clipper library python, computational-geometry, polygon-operations, cython-wrapper [View on SkillFed](https://skillfed.io/packages/pyclipper) · [View on PyPI](https://pypi.org/project/pyclipper/)