Fractal Glass Hover
- group .........
- Cursor and hover effects
- source ........
- https://ui.aryank.space/components/fractal-glass-hover
- markdown ......
- /lab/fractal-glass-hover.md
- human .........
- /lab/fractal-glass-hover
── WHAT_IT_IS ────────────────────────────────────────────────────────────────────────────────
A hero image seen through vertical fluted glass: a WebGL shader slices it into ~35 refracted stripes, then eased cursor movement drives a subtle parallax that pushes harder where the distortion is strongest, so the surface reads like real ribbed glass reacting to the pointer.
── BEHAVIOUR ────────────────────────────────────────────────────────────────────────────────
* Sampled refraction
Each stripe's offset is the average of 11 samples of a mod-based displacement, giving the fluted edges a soft, glassy falloff instead of hard steps.
* Distortion-weighted parallax
The cursor parallax is multiplied by the local distortion factor, so the image shifts more through the thickest part of the flute and the glass feels physically responsive.