python-pyclipper
Port variant v14
Summary Cython wrapper for the AJ Clipper library (3.14)
Package version 1.4.0
Homepage https://github.com/fonttools/pyclipper
Keywords python
Maintainer Python Automaton
License Not yet specified
Other variants v13
Ravenports Buildsheet | History
Ravensource Port Directory | History
Last modified 02 DEC 2025, 22:51:57 UTC
Port created 09 AUG 2020, 00:24:11 UTC
Subpackage Descriptions
single About ===== Pyclipper is a Cython wrapper exposing public functions and classes of the C++ translation of the `Angus Johnson's Clipper library (ver. 6.4.2) `__. Source code is available on [GitHub]. The package is published on [PyPI]. About Clipper ------------- Clipper - an open source freeware library for clipping and offsetting lines and polygons. The Clipper library performs line & polygon clipping - intersection, union, difference & exclusive-or, and line & polygon offsetting. The library is based on Vatti's clipping algorithm. \ [Angus Johnson's Clipper library]\ Install ======= From PyPI --------- :: pip install pyclipper From source ----------- Clone the repository: :: git clone git@github.com:fonttools/pyclipper.git Install: :: pip install . For development, use an editable install: :: pip install -e . Clippers' preprocessor directives --------------------------------- Clipper can be compiled with the following preprocessor directives: use_int32, use_xyz, use_lines and use_deprecated. Among these the use_int32 and use_lines can be used with Pyclipper. - use_int32 - when enabled 32bit ints are used instead of 64bit ints. This improve performance but coordinate values are limited to the range +/- 46340. In Pyclipper this directive is **disabled** by default. - use_lines - enables line clipping. Adds a very minor cost to performance. In Pyclipper this directive is **enabled** by default (since version 0.9.2b0). In case you would want to change these settings, clone this repository and change the define_macros collection (``setup.py``, pyclipper extension definition). Add a set like ``('use_int32', 1)`` to enable the directive, or remove the set to disable it. After that you need to rebuild the package. How to use ========== This wrapper library tries to follow naming conventions of the original library. - ClipperLib namespace is represented by the pyclipper module, - classes Clipper and ClipperOffset -> Pyclipper and PyclipperOffset, - when Clipper is overloading functions with different number of parameters or different types (eg. ``Clipper.Execute``, one function fills a list of paths the other PolyTree) that becomes ``Pyclipper.Execute and Pyclipper.Execute2``. Basic clipping example (based on [Angus Johnson's Clipper library]): .. code:: python import pyclipper subj = ( ((180, 200), (260, 200), (260, 150), (180, 150)),
Configuration Switches (platform-specific settings discarded)
PY313 OFF Build using Python 3.13 PY314 ON Build using Python 3.14
Package Dependencies by Type
Build (only) python-setuptools-scm:single:v14
python-Cython:single:v14
python314:dev:std
python-pip:single:v14
python-setuptools:single:v14
python-wheel:single:v14
python-build:single:v14
python-installer:single:v14
autoselect-python:single:std
Build and Runtime python314:primary:std
Runtime (only) ravensys-gcc:cxx_run:std (single subpackage)
ravensys-gcc:libs:std (single subpackage)
Download groups
main mirror://PYPI/p/pyclipper
Distribution File Information
9882bd889f27da78add4dd6f881d25697efc740bf840274e749988d25496c8e1 54489 python-src/pyclipper-1.4.0.tar.gz
Ports that require python-pyclipper:v14
python-booleanOperations:v14 Boolean operations on paths (3.14)