An interactive WebGL simulation of glowing threads that react to physics and mouse movement.
Important: Because this project uses JavaScript ES Modules (import/export), you cannot simply double-click index.html. It must be served via a local web server.
If you have Node.js installed, this is the quickest method.
- Open your terminal in the project folder.
- Run the following command:
npx http-server
- Open this folder in VS Code.
- Install the "Live Server" extension.
- Right-click
index.htmland select "Open with Live Server".
If you have Python installed, you can start a simple server from your terminal:
- Open your terminal in this folder.
- Run:
python -m http.server - Open your browser to
http://localhost:8000
- HTML5 Canvas & WebGL
- Vanilla JavaScript (ES6 Modules)
- GLSL Shaders (Vertex & Fragment)
main.js- Entry point, handles the animation loop.physics.js- Verlet integration and thread constraints.renderer.js- WebGL setup, shaders, and post-processing (Bloom).shaders.js- Raw GLSL shader code strings.