3.0.0 • Published 2 years ago

l-systems v3.0.0

Weekly downloads
2
License
ISC
Repository
-
Last release
2 years ago

LSystems

A little library for creating and rendering L-Systems. It's a pretty old project.

To compile, just npm install followed by npm run build. This should create an lsystems.js in the root.

There are also a couple basic tests in src/tests

What is an L-System?

It's a string rewriting system, whose output is interpreted as drawing isntructions. For more take a look here

What's inside?

A basic LSystem class, a renderer, and a generator.

For instance:

  (new lsystems.Generator).randomSystem(x);        //return a random LSystem
  (new lsystems.Generator).ruleSetRandom();        //return a random ruleset
  (new lsystems.Generator).randomSystem();         //return a random LSystem
  (new lsystems.Generator).dragonCurve();          //return an LSystem that will render to the famous "dragon curve"

See the index.html for more example code.

2.0.2

2 years ago

3.0.0

2 years ago

2.0.1

2 years ago

2.0.0

4 years ago

1.0.0

7 years ago