Skip to main content

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


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.2.tar.gz (30.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

beziers-0.0.2-py2.py3-none-any.whl (41.0 kB view details)

Uploaded Python 2Python 3

File details

Details for the file beziers-0.0.2.tar.gz.

File metadata

  • Download URL: beziers-0.0.2.tar.gz
  • Upload date:
  • Size: 30.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/18.5 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/2.7.10

File hashes

Hashes for beziers-0.0.2.tar.gz
Algorithm Hash digest
SHA256 fcb31aad2b5765a0b03bc2b850d3d33aa009c8fad5915462a2d9ebdc8b2f0da6
MD5 9793658a4c0c4b5727294a7ab0a9efc2
BLAKE2b-256 24c258c2dd543ba11cabea858637a6ef72c95eaf88a2f8f805b06a3f5f47ecd2

See more details on using hashes here.

File details

Details for the file beziers-0.0.2-py2.py3-none-any.whl.

File metadata

  • Download URL: beziers-0.0.2-py2.py3-none-any.whl
  • Upload date:
  • Size: 41.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/18.5 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/2.7.10

File hashes

Hashes for beziers-0.0.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 58c531bfd03fe8e104c720a9d47cf4ee1aed529fb8511fc1a0f4b3bcbaf0f635
MD5 3e51c126ada0466bc0d22008720103ef
BLAKE2b-256 0edac0c2a0e63da9ee956389bbffd5e72da7e7c41c7df7171966abc292ad5048

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page