06
Tunnel
Sixty-four thousand points are wound in rings around a closed 3D path, twisting as they go, and the camera rides the path looking just ahead. A rainbow cycles along the tube and linear fog swallows the far end. A dependency-free WebGL1 port of a three.js scene.
Adapted from Louis Hoebregts (CodePen) · MIT
3D pointsfly-throughfog
Live
Installation
Add it to your project
$
Installs 3 files into components/shaders. The tunnel brings its own renderer, so it needs nothing else.
Usage
Mount it behind your content
app/hero.tsx
The shader fills its nearest positioned ancestor. Give the parent relative isolate and the shader -z-10 to put it behind everything else.
API reference