Fluid Refraction
- group .........
- Cursor and hover effects
- source ........
- https://ui.aryank.space/components/fluid-refraction
- markdown ......
- /lab/fluid-refraction.md
- human .........
- /lab/fluid-refraction
── WHAT_IT_IS ────────────────────────────────────────────────────────────────────────────────
Pointer-driven fluid refraction over an image or video. Raw WebGL simulates velocity, pressure and density, then samples the media with RGB separation and highlights. Pure React and TypeScript.
── BEHAVIOUR ────────────────────────────────────────────────────────────────────────────────
* Media, not a model
The metallic ribbon and slogan are pixels in the demo image. The GPU simulates fluid density and samples that image with refraction, chromatic separation and highlights.
* Independent GPU resources
Each instance owns its half-resolution velocity, pressure and density buffers. Resize and unmount release them. Offscreen/hidden scenes pause.
* Reduced motion and fallback
Reduced motion renders the media without moving fluid. Unsupported half-float WebGL uses ordinary cover-cropped media.
* Original source
Ported from real-result-504144.framer.app with its original image and simulation settings in the demo.