Components
A React UI component that renders morphing, glowing liquid blobs—fluid crystal-like shapes that merge and separate—using WebGL2 and GLSL SDF techniques.

import React from "react";
import LiquidCrystalBackground from "@/components/ui/liquid-crystal-shader";
const settings = {
speed: 0.6,
radii: [0.25, 0.18, 0.3],
smoothK: [0.2, 0.3],
};
export default function DemoOne(props: Partial<typeof settings>) {
const s = { ...settings, ...props };
return (
<div className="h-screen w-screen">
{/* Liquid-Crystal background with default settings */}
<LiquidCrystalBackground
speed={s.speed}
radii={s.radii}
smoothK={s.smoothK}
/>
{/* Content overlay */}
<div className="absolute inset-0 z-10 flex flex-col justify-center items-center text-center pointer-events-none px-4">
<h1 className="text-6xl font-black leading-tight">Liquid Crystal</h1>
<p className="mt-4 text-lg text-muted-foreground max-w-xl">
A smooth, lava-lamp style GLSL shader in WebGL2, fully customizable
via props and theme-aware through CSS variables.
</p>
</div>
</div>
);
}