
Fractal Glass
WebGL
A pointer-led WebGL pixelation effect that reveals image detail through cursor movement for portfolios, campaigns, and technical hero surfaces.
Mouse Pixelation reveals content through cursor movement. It makes the act of looking the first interaction.
Use it when pointer movement should make the hero feel discovered: portfolio imagery, technical visuals, or campaign surfaces where the reveal adds meaning.
The risk in production is pointer dependence. The final image and message must be available when hover is unavailable.
import MousePixelation from '@/components/effects/mouse-pixelation' const page = () => { return ( <> <MousePixelation variant={"pixel-circle"} imageUrl={"https://pub-8abee449136941f5b0a1cd2c014534e9.r2.dev/vault-listing-images/assets-images/h-02.jpg"}/> </> )} export default pageA photographer's portfolio can use Mouse Pixelation on the opening image of a new series. The photograph sits behind a pixel grid, and cursor movement shifts the blocks so the visitor uncovers detail by looking around the frame.
The outcome is discovery. The first interaction is the act of looking, which suits work that rewards a second glance. The series title, credits, and the full image stay available for touch visitors who cannot hover.
A creative campaign page can use the same component when pixelation is already part of the visual language.
Not for low-power-first pages, dense content, dashboards, checkout, or routes where performance is the main conversion lever.
Cap DPR at 1.0 on touch/mobile and up to 1.5 on mid-range desktop. Pause Mouse Pixelation offscreen and in hidden tabs, reduce postprocessing before shipping, and keep texture sizes controlled.
Keep meaningful content in HTML outside the canvas. On mobile, reduce shader quality and switch to a poster if the scene cannot hold frame rate.
| Prop | Type | Default | Description |
|---|---|---|---|
v1NumberOfGrids | number | 35 | V1 · Pixel Circles: number of grid cells across the effect. |
v1Lerp | number | 0.1 | V1 · Pixel Circles: smoothing of the mouse-following motion. |
v1BackgroundColor | string | #000000 | V1 · Pixel Circles: canvas background color. |
v2NumberOfGrids | number | 35 | V2 · Pixel Shift: number of grid cells across the effect. |
v2Lerp | number | 0.1 | V2 · Pixel Shift: smoothing of the mouse-following motion. |
v3NumberOfGrids | number | 35 | V3 · Pixel Cube: number of grid cells across the effect. |
v3Lerp | number | 0.1 | V3 · Pixel Cube: smoothing of the mouse-following motion. |
v3CubeSize | number | 1 | V3 · Pixel Cube: scale of the cube. |
v3GridEmbossing | number | 1 | V3 · Pixel Cube: depth of the extruded grid. |
The pixelation samples the image as the cursor moves, so cap DPR at 1.0 on mobile and 1.5 on desktop and keep the source texture appropriately sized. Update the effect around the pointer rather than the whole frame where possible. Note that the core interaction is pointer-based, which shapes the mobile story.
Show the clean, un-pixelated image so the content is fully visible without the effect. The HTML copy is unaffected. Make sure nothing important depended on pixelation to be seen.
Pause rendering and pointer tracking when the canvas is offscreen or the tab hidden, and idle when the pointer is away. Resume on visibility and interaction. Idling between movements keeps it inexpensive.
Real content stays in HTML; the pixelation is a visual layer over imagery, not a place to store text or links. Because the reveal is pointer-driven, ensure touch and keyboard users still get the full image and meaning. Keep actions as DOM elements.
Choose a static image when most traffic is touch (where there's no hover to drive the effect), when performance matters, or when the pixelation is novelty rather than purpose. If the interaction won't reach your audience, show the plain image. Reserve it for pointer-first, exploratory pages.
Need a custom effect? Tell us what to create.