This repo defines a framework for creating a grid of randomly generated 'components'.
git clone https://github.com/jessburnsm/generative_art.git- Open the
generative_art/index.htmlfile in a browser window. - Refresh the page to re-generate the grid.
- Click
SAVE SVGon the page to save the current grid as an image.
Global options can be set in js/sketch.js:
- Change the
PALLETEarray to alter the color scheme of design elements. All colors should be specified in RGBA format. - Change the
MIN_STROKEandMAX_STROKEvalues to change the thickness of element strokes. - Change the value of
DEBUGto toggle the debug window. - Update
ELEMENT_LIBRARYto alter which design elements can be drawn. All values should correspond to a design element class. Add a class to the list more than once to increase its likelihood to be drawn on any given iteration.
Design elements are individual geometric components. They are drawn with random parameters. Parameters for each design element can be seen in debug mode.
A component is a set of design elements. Components choose a random number of
design elements to apply from the ELEMENT_LIBRARY.
The grid is an n x n collection of components.