Bezier curve manipulation library
Project description
Beziers provides a variety of classes for constructing, manipulating and drawing Bezier curves and paths. Principally designed for font design software, it allows you to join, split, offset, and perform many other operations on paths.
Here is an example session:
from beziers.point import Point from beziers.path import BezierPath from beziers.cubicbezier import CubicBezier b1 = CubicBezier( Point(412.0,500.0), Point(308.0,665.0), Point(163.0,589.0), Point(163.0,504.0) ) b2 = CubicBezier( Point(163.0,504.0), Point(163.0,424.0), Point(364.0,321.0), Point(366.0,216.0) ) b3 = CubicBezier( Point(366.0,216.0), Point(368.0,94.0), Point(260.0,54.0), Point(124.0,54.0) ) path = BezierPath.fromSegments([b1,b2,b3]) path.closed = False path.addExtremes() path.balance() path.translate(Point(-100.0,-100.0)) import matplotlib.pyplot as plt fig, ax = plt.subplots() path.addExtremes() path.plot(ax) plt.show()
Full documentation is available at https://simoncozens.github.io/beziers.py/index.html
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
beziers-0.0.5.tar.gz
(33.0 kB
view hashes)
Built Distribution
Close
Hashes for beziers-0.0.5-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 931d881de8e11fe3e3004ab976a40dbce55ca523bc3d7ccef6aa150cb068118b |
|
MD5 | 984f9a74ba23a994ef1f09f8df62a552 |
|
BLAKE2b-256 | 98629dfb06d8a7da4198cdda30dfb9d6c54a7edbed049afe73a0b235c7cbe63a |