Docs/Formas

Brushed Metal

MIT

Photorealistic brushed metal — a satin anodised surface combed with fine directional grain that smears the reflected studio and key light into the long anisotropic streaks of real brushed aluminium, steel, gold or copper

Cargando shader…

Ajústalo

1
0
0
0.4
0.4
2
0.5
1.4

Instalación

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

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

Uso

Demo.tsx
1import ShaderBrushedMetal from '@/components/bastard/ShaderBrushedMetal';
2
3export default function Demo() {
4 return (
5 <ShaderBrushedMetal
6 scale={1}
7 rotation={0}
8 lightColor="#e9ebef"
9 darkColor="#26282d"
10 brushAngle={0}
11 anisotropy={0.4}
12 grain={0.4}
13 grainScale={2}
14 roughness={0.5}
15 environment={1.4}
16 />
17 );
18}

Props

PropTipoPor defectoDescripción
scalenumber1Scale
rotationnumber0Rotation
lightColorstring"#e9ebef"Light Color
darkColorstring"#26282d"Dark Color
brushAnglenumber0Brush Angle
anisotropynumber0.4Anisotropy
grainnumber0.4Grain
grainScalenumber2Grain Scale
roughnessnumber0.5Roughness
environmentnumber1.4Environment

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

Créditos

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