Audio-reactive WEBGL helix with a VHS-ish post FX pass and a dissolve mixer (clean ↔ FX).
This repo intentionally ships without media assets so anyone can drop in their own audio/video.
- A modern browser (Chrome / Firefox / Safari)
- A local web server (recommended; required for loading audio/video reliably)
Browsers generally block autoplay audio. This sketch starts after the audio is loaded and you click.
From the project folder, start a server:
bash python3 -m http.server 8000
Then open:
http://localhost:8000
bash npx serve .
Place files at these paths (see also assets/README.md):
assets/audio/main.wav— main audible track (required)assets/audio/kick.wav— kick/bass driver (optional; used for displacement)assets/video/strands.mp4— helix strand texture (required)assets/video/nodes.mp4— node sphere texture (optional; falls back tostrands.mp4)
You can change the paths in src/config.js under CONFIG.assets.
Scripts are loaded directly via <script> tags in index.html:
src/config.js— tweak knobs + asset pathssrc/shaders.js— GLSL stringssrc/tunnelField.js— displacement history buffersrc/dnaHelix.js— helix renderersrc/scene.js— audio analysis + breathing + camera + scene drawsrc/post.js— VHS pass + dissolve + presentsketch.js— p5 lifecycle + wiring
- For 4K output, keep
pixelDensity: 1unless you specifically want retina supersampling. - If performance is tight, reduce
CONFIG.canvas.w/hor lowerCONFIG.dna.nodes.