Splashery
Playground

Quick reference

One splat

G(p) = exp(−½ (p − μ)T Σ−1 (p − μ)),   Σ = R S ST RT

Σ′ = J W Σ WT JT,   C ← a c + (1 − a) C (back to front)

A splat program

x = …        y = …        z = …        # in u, v and t (y is up)
u = 0 .. 2pi                           # ranges: numbers only
v = 0 .. pi                            # default 0 .. 1
hue = …                                # 0 red, 1/3 green, 2/3 blue
r = …   g = …   b = …                  # or colors from 0 to 1
size = 0.05                            # about the bell's σ
count = 4000                           # 100 to 10,000
spread = grid                          # or random

Functions: sin, cos, tan, asin (arcsin), acos (arccos), atan (arctan), sinh, cosh, tanh, exp, log (ln), log10, sqrt, abs, floor, min, max. Constants: pi, e. Time: t runs from 0 to 2π per tap. At most 240 characters an expression (each end of a range counts on its own).

A picture Splash

pictures: { sample: () => "assets/…", accept: ["pdf", "image", "gif", "video"] },
input: { title, media: { accept } },     // or placeholder, button, read, shown; or pad
tiltLock: true,                          // a drag turns it only left and right
build(k) { k.sheet({ id, center, width, height, leaf }); k.spine({ at, axis, dir }); },
drive(t, c, out, info) {
  out.sheets[id] = { page, visible };    // pages count from 0
  out.leaves[slot] = { angle, curl };    // radians; 0 flat, pi turned over
  info.data.pictures                     // page, count, go(n), next(), prev(), togglePlay()
}

A recipe (a Splash)

export const RECIPES = { "my-toy": {
  options: [{ key, label, type, default }],   // saved in the link
  controls: [{ key, label, type: "slider" | "toggle" | "pulse", ease }],
  action: { key, label },                     // the tap
  build(k, o) { /* k.sphere, k.box, k.part(name, { pivot, axis }), k.add(shape, { part, pos, color }) */ },
  drive(t, c, out, info) { out.parts[name] = { angle }; },  // every frame
  hands: { pieces, joints, ropes, material },  // the ✋ switch (Chapter 6)
  handsOn: false, tiltLock: true, turntable: false,
}};

The controls

Drag, pinch, scroll Turn, zoom (two fingers roll only after a twist of about 17°)
Shift or Option/Alt and a drag; two-finger drag Move the Splash across the screen
The Reset button; double-tap or double-click on most Splashes Reset the view
R Record
1 to 5 Only in a Splash with its own tool row: in Splat Name, Spin, Poke, Paint, Drop, and Blow
F Full screen
Esc Close the gallery or a sheet
Focus mode Automatic: after 5 seconds untouched the controls fade; touch the strip at the top or bottom, or press a key, to bring them back
G Open the gallery (on a computer)
T, H, M Turntable, Hands-on, sound
Space Pause and play everything that moves (it holds all audio)
Hold L Pull the frame apart into its layers; let go to put it back
Arrows, + and −, Enter Turn, zoom, tap the Splash
Hold B Draw a box on a picture Splash
✋ Hands-on: drag to pick up, let go to toss, ↺ to send home
Padlock, record player (buttons on the stage) Tilt lock (a drag turns left and right only), turntable when idle
A W S E D F T G Y H U J K O L P ; ', Z, X On a piano with falling keys, play the notes from a C near the middle; Z and X move an octave down and up
?labs=1 or ?labs=0 Show or hide the Splashes not yet ready for everyone

Key numbers

What Number Chapter
Splats a Splash opens at Set for each Splash and tier: about 200,000 at Mid for most kit Splashes; the Splats slider goes up to about 1,000,000 2
Splats of Splat Equation 100 to 10,000 3
Characters in one equation field 240 3
Option keys of Splat Equation 16 3
Moments of t 12 3
Parts, besides the body 15 2
Tokens, levers, lever groups 48, 96, 6 2
Hands-on: gravity, throw cap 26 and 4 Splash radii per second (squared for gravity); 4 is the base cap, and a material can scale a throw to 5 6
Hands-on: collision points of a Splash 64, from up to 6,000 splats 6
Stars in Night Sky HYG's catalog to magnitude 6, plus 20,720 fainter stars (6.0 to 7.5) 7
Largest molecule, volume 250,000 atoms; 8 million voxels 7
Depth model 27.3 MB (plus a 14.2 MB runtime), or about 77 MB the first time with WebGPU; loaded only for your own photo, a clip, or the camera 8
3D Video, clip length 8 seconds for a GIF or a short clip (a longer video plays whole) 8
QR code error correction L 7%, M 15%, Q 25%, H 30% of codewords 9
A link No limit of its own; version 21 QR code up to 711 characters at M 9

What goes where

Splat files (.ply, .sog, .splat, .spz), models (glTF, GLB, OBJ, STL), pictures (PDF, photo, GIF, video), data (CSV, DICOM, NIfTI, TIFF, LAS, LAZ, PDB) are opened on your device and never uploaded. A link carries settings, not files.