Diorama

Made for a big screen.

This site is one 3D scene, built for a computer: a wide window and a mouse. Open dioramajs.dev on a desktop or a laptop to see it.This site is one 3D scene, built for a wide window. Make this one wider, or open dioramajs.dev on a larger screen.

GitHub

DioramaDocs

Puff interface

The puffed letters of a raster: the distance to their edge and how round each part is.

View as Markdown
import type { Puff } from '@dioramajs/text/inflate'
interface Puff

Members

NameTypeDescription
readonly dataUint16Array

Per texel, half floats: the signed distance to the glyph edge in CSS px (positive inside), the height of the round profile at depth 1 in CSS px, the turn of the nearest letter, and that height as a share of the profile's radius (0 at the edge, 1 on the ridge).

readonly emnumber

Largest font size, px.

readonly framereadonly [number, number, number, number]

The field in box px: x, y, width, height.

readonly heightnumber
readonly widthnumber

Defined in packages/text/src/inflate.ts.