FreeEffects and animation

Liquid metaballs

Colored blobs that drift, melt into one another like liquid, and blend their colors as they merge.

Free
Free with a ShipSwift account.

Copies a short instruction with your private download link. Paste it into your agent: it downloads the whole skill (the source code, the setup steps and the mistakes we already made for you) and builds the screen.

Works with

+70

What it does

Gooey procedural background of soft blobs rendered through SwiftUI's colorEffect Metal pipeline. No source view is required — SWMetaballs() renders standalone over its background color.

A style system selects between two looks:

  • `.cluster` (the original) — blobs meander on independent noise drifts; each blob picks its color by index from a 1–8 entry palette and the shape-weighted average produces the merged, gooey look.
  • `.fountain` — a big central ball with small balls streaming vertically. Roughly half the small balls rise from the bottom and converge into the big ball, the other half leave the big ball and spread upward out of frame. Because all shapes are summed before the threshold, a small ball melts into a teardrop bridge as it nears the big ball (the metaball "merge"), then separates again as it travels. A small ball's color is blended toward the big ball's the nearer it is to the centre, so it dissolves in like two liquids mixing rather than staying a distinct dot.

Requires iOS 18+ / macOS 15+ (SwiftUI ShaderLibrary / Shader / Metal stitchable).

What you get

  • ✓631 lines of source code, ready to paste
  • ✓File Layout
  • ✓Parameters
  • ✓Source Code
animationmetalshaderSwiftUI

More in Effects and animation

Metal dot fields
Free
Metal shaders: fields of dots that roll like waves and flow into living patterns, all drawn on the GPU.
Deep-space starfield
Free
A deep-space starfield in Metal: glowing nebulae drift past twinkling stars.
Neon outlines
Free
Neon outlines that bloom from the center with prism-colored edges, rendered live in Metal.
3D network graph
Free
A 3D network graph you can spin. Tap any node and its links light up, with the details below.
Orbit ring and wallet
Free
Items orbit into a dotted ring, and payment cards fan out of a wallet as the balance rolls in.
Floating color dots
Free
A field of bright colored dots that float and shimmer across the whole screen.
Glass color panels
Free
Stacked glass panels in mirrored layers, with neon gradients flowing through them.
Dot sphere
Free
Drag the slider and scattered points of light pull together into a perfect 3D sphere.
Cells and swirl
Free
Living patterns: a mosaic of cells that keeps reshaping, then a hypnotic color swirl.
Noise veins and blobs
Free
Organic noise shaders: glowing veins that pulse through the dark, then bold color blobs in constant flow.