Docs/Efectos

Bokeh Blur

MIT

Photographic lens blur where bright highlights bloom into aperture-shaped discs

Cargando shader…

Ajústalo

50
4
0.6
6
0
0.2
0

Instalación

Terminal
npx shadcn@latest add https://<tu-dominio>/r/shader-bokeh-blur.json

Crea components/bastard/ShaderBokehBlur.tsx e instala shaders. Más opciones

Uso

Demo.tsx
1import ShaderBokehBlur from '@/components/bastard/ShaderBokehBlur';
2
3export default function Demo() {
4 return (
5 <ShaderBokehBlur
6 radius={50}
7 highlightGain={4}
8 highlightThreshold={0.6}
9 bladeShape="blades"
10 bladeCount={6}
11 bladeRotation={0}
12 chromaticFringe={0.2}
13 catEye={0}
14 />
15 );
16}

Props

PropTipoPor defectoDescripción
radiusnumber50Radius
highlightGainnumber4Highlight Bloom
highlightThresholdnumber0.6Highlight Threshold
bladeShape'blades' | 'circle' | 'star' | 'heart' | 'flower' | 'cross' | 'ring'"blades"Blade Shape
bladeCountnumber6Aperture Blades
bladeRotationnumber0Blade Rotation
chromaticFringenumber0.2Chromatic Fringe
catEyenumber0Cat Eye

Aquí aparecen las props ajustables. El componente acepta más: revisa el código fuente.

Créditos

Basado en Bokeh Blur · Shaders.com, adaptado para BSTRD UI.Licencia: MIT. Puedes usarlo, modificarlo y venderlo, conservando el aviso de copyright que va dentro del archivo.