Skip to content

Transform Loupe Hero

A first screen whose picture is computed live: a plane of spheres under a low sun, printed in blue-noise dither, with a loupe under the pointer that shows it as shape-matched ASCII, a halftone screen, Bayer or the source.

ProDither & ASCIIminimalneon

This is a viberdy Pro component

The live preview, the props panel and the write-up are open to everyone. The full source, the AI prompt and CLI install are part of Pro.

Preview

Dotplane · Image pipeline

Every pixel,placed.

Transform, dither and deliver images from the edge. One request, every output: from 1-bit to full tone, in the time it takes to load.

Start buildingSee the transforms

GET /v1/i/dot-plane.png?t=ascii&glyph=11

Props

Request line
No runtime dependencies
"use client";

import { useEffect, useRef, useState, useSyncExternalStore } from "react";
import type { CSSProperties, KeyboardEvent as ReactKeyboardEvent, PointerEvent as ReactPointerEvent, ReactNode, RefObject } from "react";

/**
 * TransformLoupeHero — a first screen whose picture is computed live, with a loupe of another transform.
 *
 * A plane of spheres under a low sun is traced in WebGL2 (soft shadows,
 * occlusion, a haze, the sun's glint in every sphere) and printed in
 * blue-noise dither, one cell per two CSS pixels, snapped to device pixels.
 * Under the pointer a loupe shows the same scene as shape-matched ASCII, a
 * halftone screen, Bayer or the source; the keys pick which, and the change
 * dissolves through blue noise. Drag across it to move the sun. Pass `image`
 * to transform your own picture instead. Draws only on screen; without
 * WebGL2 a CSS dither of a still stands in.
 *
 * Part of the Dither & ASCII kit: one ink, paper #f3f0e6, on a warm black

  // ---------------------------------------------------------------
  // Full source available with a viberdy Pro subscription.
  // https://viberdy.dev/pricing
  // ---------------------------------------------------------------
}
Notes

About this heroe

The first screen of an image pipeline, where the picture is the product working. A plane of spheres stretches to the horizon under a low sun, traced live in WebGL2 with soft shadows, occlusion between the spheres and a haze at the horizon, and every sphere carries a tiny vermillion glint of it. The whole scene is printed in blue-noise dither, one cell per two CSS pixels, snapped to the screen's own pixels so it never blurs into grey. Under the pointer a loupe shows the same scene through another transform: shape-matched ASCII (glyphs chosen by the shape of each cell, so edges get slashes instead of staircases), a rotated halftone screen, Bayer 8x8 or the untouched source. The keys choose the transform and it dissolves in through blue noise; a mono request line names it. Drag across the hero to move the sun and every shadow swings round. Pass an image to transform your own picture instead.

Curator’s note

The Dither & ASCII kit's hero (slot 1, Featured), cut from dither-ascii-site. Pro: the kit's WebGL2 stage with a traced scene, blue-noise dither, a loupe of four transforms (shape-matched ASCII among them) that dissolve into each other, and a draggable sun.

Related

Pairs well with

Matched on shared tags and category — the entries most likely to be used alongside this one.

Trending
Pro

A raymarched glass prism on black: a white beam comes in from wherever your pointer is, a spectrum fans out the other side, and the prism turns once a minute. One shader, no libraries.

herowebglshader
NewPro

One source through every transform, split by a wipe you drag: a raymarched still life on the left, and on the right true Atkinson or Floyd–Steinberg diffusion, blue noise, Bayer, halftone or shape-matched ASCII.

sectionwebgldither
Featured
Pro

A slab of liquid glass you drag across a vivid scene: the headline bends under its rim, colours split at the edge, and it wobbles like gel. Two WebGL passes, no libraries.

herowebglshader