Skip to main content

Python package for 2D and 3D rendering of GerberX3 files.

Project description

https://raw.githubusercontent.com/Argmaster/pygerber/main/docs/_static/pygerber_logo.png

Overview

PyGerber is a Python library for 2D and 3D rendering of Gerber X3 files. It is completely written in Python, and only dependencies are limiting its portability.

This package is a Free Software; it is released under MIT license. Be aware that dependencies might be using different licenses.

PyGerber offers a CLI and API for Python to allow easy rendering of Gerber files. Parser was build with GBR X3 format in mind, however, it has extensive support for older standards and deprecated features. Package is using third party libraries for low level drawing and mesh creation.

PyGerber’s parser was not ment to be used by package users, but there are no obstacles preventing you from using it. However, stability of the API is not guaranteed between minor releases (I’ll do my best to make it stable among patches).

Installation

PyGerber is available on PyPI and can be obtained via pip

pip install pygerber

You can also install the in-development version from github with

pip install https://github.com/Argmaster/pygerber/archive/main.zip

Blender dependency issue mentioned in previous releases was resolved by using PyR3 package which provides Blender. However, blender has to be installed independently from package by calling PyR3.install_bpy script:

python -m PyR3.install_bpy

Before You try to use 3D rendering.

Compatibility

PyGerber officially runs on Python 3.9.* and only on this version. However it may be possible to run 2D rendering on other Python versions that are supported by Pillow.

I’ll consider bringing Python 3.8 3D rendering support, but no sooner than after implementation of full set of 3D rendering features and macros support.

Documentation

Documentation of this library is available at https://pygerber.readthedocs.io/

Development

To run all the tests, just run:

tox

To only build the docs:

tox -e docs

To build and verify that the built package is proper and other code QA checks:

tox -e check

Changelog

0.0.0 (2021-09-25)

  • First release on PyPI.

  • Added 2D rendering

1.0.0 (2021-10-06)

  • Added 3D rendering (not full-featured)

  • Added CLI and API for 3D rendering

  • Installing bpy is required for 3D rendering

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

pygerber-1.0.0.tar.gz (1.7 MB view details)

Uploaded Source

Built Distribution

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

pygerber-1.0.0-py3-none-any.whl (55.3 kB view details)

Uploaded Python 3

File details

Details for the file pygerber-1.0.0.tar.gz.

File metadata

  • Download URL: pygerber-1.0.0.tar.gz
  • Upload date:
  • Size: 1.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.5

File hashes

Hashes for pygerber-1.0.0.tar.gz
Algorithm Hash digest
SHA256 901fdcc57d5f3e1f40fa314d6cffb165132081ac2e86835ab6520a3b18ceb2ae
MD5 613b66cdf50968064f3fc04fa7ab0859
BLAKE2b-256 8a7c34857506a2d41016965cf03a447659afdcbd7ad04f4ff510f0c02d0e070f

See more details on using hashes here.

File details

Details for the file pygerber-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: pygerber-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 55.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.5

File hashes

Hashes for pygerber-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 93406711d5029180173ec4bc163dcd9308eb9ff5551202c5cf1a85cc8cf6d0bf
MD5 5ccd75176fe6a85938e3464fcb12d8c8
BLAKE2b-256 fdc2146d2276c61448dfd190ffbba875bea02222bd3ab41f4769a69600c206de

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