Creative Coding: Pattern Machine II

This project was to explore pattern generation, creating a system to endlessly generate patterns in a defined visual language.


Originally inspired from the 10Print pattern sequence, I was captivated with just how the simple glyphs of a forward slash and a backward slash could create virtually infinite maze-like patterns, the small 45 degree slashes connecting to create lobe-like passages and pathways across the screen; building a pattern of increasing complexity.

What was equally captivating was the hypnotic element of watching the pattern being created in real-time. As though you’re witnessing a timelapse of architectural marvel.


I knew this would be an exercise I would perform in p5.js, and though the 10 Print sequence came quickly and a subsequent user-influenced variation (below) came after, I couldn’t help but take it further.

This uses mouse detection. Positioning the mouse to the left increases the probability of a backslash whereas positioning the mouse to the right increases the probability of a forwardslash.



Finding pattern influence from a previous study I did in regard to Anni Albers and Armin Hofmann…

I planned an algorithm to take a pattern in a visual language of this sort and continually evolve and vary the pattern for virtually infinite results – like the  10 Print sequence.

The pattern is simply based on one square with eight points, four of which continually move to the same centre point at random.

Which is then multiplied and layered with colour for complexity.

I was then thinking about how this could be used as a swatch builder to create patterns for application, whether that be for textiles, tiles, or tupperware.

For this, I put in colour controls, a brightness control, a swatch size slider, and a density switch along with an export function.


Of course, ‘controls’ aren’t necessarily the best way to think, it’s more influence. The pattern itself is still very much its own animal, the user only pulling the composition one way or another through colour, size, density, and tone.


Like the hypnotic nature of a lava lamp, a lapping tide, or the 10 Print sequence, the audience feels secure in what each iteration will bring, however, each iteration is unique enough that the observer genuinely has a preference of one output over another, keeping them watching, observing, and inspecting what the next iteration in this algorithm could bring.

Here’s an installation piece made from the same algorithm intended for large-scale projection and sound (click to reset colours).