generativepy

By Martin McBride, 2023-05-15

generativepy is an open-source Python library for creating generative art, maths illustrations and maths animations.

The main functions of the library are:

  • A simple framework for creating images, image sequences, and gifs, using pycairo.
  • Support for bitmap processing using PIL and NumPy.
  • Colour module that supports RGB, HSL and CSS colours, transparency, lerping, colormaps.
  • A simple tweening module to help with animation.
  • Geometry module for drawing shapes.
  • A graphing library for plotting 2D functions.
  • MovieBuilder supports creating video files from separate scenes.
  • Latex formula rendering
  • 3D geometry module using moderngl.
  • Math modules for vectors, matrices and abstract shapes.

The source code is available on github. generativepy can also be installed from PyPi using pip.

This website provides the following documetation:

genpygoodies library

The genpygoodies library provides a variety of additional functions and classes that I have developed for my own use, and that you might find helpful. It is entirely optional, you can use generativepy without genpygoodies.

The source code is available on github.

There is a separate API reference for genpygoodies.

Join the GraphicMaths Newletter

Sign up using this form to receive an email when new content is added:

Popular tags