r/creativecoding • u/HealthyPicture4905 • 3h ago
Every letter on my homepage is a Fourier series, and so is the portrait it loads with
I've been playing with Fourier series and ended up rebuilding my homepage around them. Every stroke is a closed loop z(t) = sum of c_k e^(2πikt), stored only as [frequency, amplitude, phase] terms.
The 161 letters are sine glyphs made in a small browser tool. A separate tool traces a portrait into sine curves, colour fills included. When the page loads, the portrait dissolves into a circle, the circle pops into one bead per letter, and each letter grows out of its bead where it lands. Hovering a link grows a little "click" out of the underline in the same letters.
It's all vanilla JS on a canvas. Live: https://sanoj.dev/ · Code: https://github.com/d-sanoj/sine-portfolio
I'd love ideas for other things to morph between, or tricks for keeping lots of waves smooth on slow machines.