Concept
I wanted to experiment with ASCII art in a dynamic way, using Perlin noise and interactive effects to create an evolving text-based visualization (I got inspired by the Coding Train videos on Perlin noise and this image manipulation + ASCII density coding challenge by him).
Each character is selected based on noise values, and their colors shift over time. As the mouse moves, it creates a ripple effect by “pushing” nearby characters away, giving a fluid and organic motion to the grid.
Demo (Click on canvas)
Code Highlight:
This part of the code uses Perlin noise to smoothly select characters from the density
string and generate dynamic colors for each character.
// Using Perlin noise for smoother character selection let noiseVal = noise(i * 0.1, j * 0.1, frameCount * 0.02) * density.length; let charIndex = floor(noiseVal); let char = density.charAt(charIndex); // Generate color based on Perlin noise let r = noise(i * 0.05, j * 0.05, frameCount * 0.05) * 255; let g = noise(i * 0.07, j * 0.07, frameCount * 0.05) * 255; let b = noise(i * 0.09, j * 0.09, frameCount * 0.05) * 255; fill(r, g, b); text(char, newX, newY);
How it works:
noiseVal
determines the ASCII character by mapping noise to thedensity
string length.r
,g
, andb
are also mapped to Perlin noise, creating a smooth, organic color transition over time.
Reflection & Improvements for Future Work
This experiment opened up some interesting possibilities for ASCII-based generative art. I’d love to refine the animation by adding more layers of motion, perhaps introducing gravity-like effects or different interaction styles. Another idea is to use real-time audio input to influence the movement, making the piece reactive to sound. Definitely a fun one to explore further!
I like the aesthetics of this one, it has a bit of a Matrix vibe.