Pixel Throw
MITThrows pixels along the cursor's path like a fluid — brighter (or redder/greener/bluer) pixels are flung farther, then settle back with friction
Cargando shader…
Ajústalo
0.25
0.8
0.2
0.3
0.5
Instalación
Terminal
npx shadcn@latest add https://<tu-dominio>/r/shader-pixel-throw.json
Crea components/bastard/ShaderPixelThrow.tsx e instala shaders. Más opciones
Uso
Demo.tsx
1import ShaderPixelThrow from '@/components/bastard/ShaderPixelThrow';23export default function Demo() {4 return (5 <ShaderPixelThrow6 throwKey="luminance"7 strength={0.25}8 keyInfluence={0.8}9 radius={0.2}10 friction={0.3}11 momentum={0.5}12 edges="stretch"13 />14 );15}
Props
| Prop | Tipo | Por defecto | Descripción |
|---|---|---|---|
| throwKey | 'luminance' | 'darkness' | 'red' | 'green' | 'blue' | "luminance" | Throw By |
| strength | number | 0.25 | Strength |
| keyInfluence | number | 0.8 | Key Influence |
| radius | number | 0.2 | Radius |
| friction | number | 0.3 | Friction |
| momentum | number | 0.5 | Momentum |
| edges | 'stretch' | 'transparent' | 'mirror' | 'wrap' | "stretch" | Edges |
Aquí aparecen las props ajustables. El componente acepta más: revisa el código fuente.
Créditos
Basado en Pixel Throw · Shaders.com, adaptado para BSTRD UI.Licencia: MIT. Puedes usarlo, modificarlo y venderlo, conservando el aviso de copyright que va dentro del archivo.