Skip to content

radiodario/differential-line

 
 

Repository files navigation

Differential Line

ani

This algorithm is inspired by the way a number of biological things in nature grows. Among other things it is made to mimic the growth of the human brain, as well as a great number of plants.

img

In brief; we start of with a number of connected nodes in a circle. Gradually we introduce new nodes on the line—prioritizing segments where the curve bends more sharply. Over time the curve grows increasingly intricate, but it never self-intersects.

img

img

If we start with a different shape, and draw the outside position of the object for each growth step, we can get an entirely different kind of system with an interesting 3D illusion.

img

Prerequisites

In order for this code to run you must first download and install these two repositories:

Other Dependencies

The code also depends on:

  • numpy
  • cython
  • python-cairo (do not install with pip, this generally does not work)

Running it on Linux (Ubuntu)

To install the libraries locally, run make. I have only tested this code in Ubuntu 14.04 LTS, but my guess is that it should work on most other platforms platforms as well. However i know that the scripted install in make will not work in Windows

Running it on OS X

To install on OS X, you'll need to install OpenMP / Clang, and then have cc linked to that installation. So, in the differential-line directory:

$ brew install clang-omp
$ ln -s /usr/local/bin/clang-omp /usr/local/bin/cc
$ make
$ rm /usr/local/bin/cc

Also, you'll need to have pygtk installed to run the included files.

$ brew install pygtk

You should now have a working copy installed.

Running it on Windows?

The code will probably work just fine under Windows, but I'm not sure how to install it. (Let me know if you get it working!)

Similar code

If you find this alorithm insteresting you might also want to check out: https://github.com/inconvergent/differential-mesh.


http://inconvergent.net

Releases

No releases published

Packages

No packages published

Languages

  • Python 99.5%
  • Makefile 0.5%