Made by AI
Space Travel · Interactive explainers

How the demo works

Space Travel is a real-time demo in the spirit of the Amiga and PC demoscene: fifteen procedural space scenes, about five minutes, synced to a tracker tune. These pages take each scene apart. Every page runs the demo's real shaders live in your browser, then explains the ideas behind them one at a time — from first principles, with small figures you can play with — and ends with step-by-step pseudo-code and the actual source.

Companion to the printed art book (SpaceTravel-ArtBook.pdf (opens in a new tab)). Works offline: each page is a single file. Needs a browser with WebGL2 (any current Edge, Chrome or Firefox).

The scenes

01
Intro
Chrome logo, copper bars and a sine scroller — one fragment shader.
8×8 font · copper bars · sine scroller · beat sync
02
Parallax stars
Layers of stars sliding past a planet.
parallax · geometry from gl_VertexID · planet shading
03
Nebula pillars
Dust pillars lit from behind by a star cluster.
volumetric ray marching · light shafts · 3D noise
04
Warp
The jump to hyperspace.
motion blur · hashes · integrated speed · tunnel noise
05
Giant star
A boiling stellar surface with corona and flames.
ray–sphere · turbulent noise · glow
06
Asteroid chase
A fighter skims rocks through their shadows.
procedural meshes · shadow maps · instancing
07
Ringed giant
A gas giant and its rings, casting shadows on each other.
raytracing · ring shadows · scattering
08
Canyon run
Low and fast through a dusty canyon.
heightfield ray marching · fog · depth hand-off
09
Fleet jump-in
A fleet drops out of hyperspace on the beat.
instancing · flashes · music sync
10
Dreadnought
A slow patrol under a giant capital ship.
procedural model · self-shadowing · reflections
11
Supernova
A red giant collapses and explodes.
expanding volume · emission · debris particles
12
Wormhole
Through the throat to another sky.
gravitational lensing · two skies · tunnel
13
Galaxy
A spiral galaxy built from millions of points.
nested ellipses · PCG hashes · gas and dust
14
Black hole
An accretion disc bent around the event horizon.
bending light · Doppler beaming · lensing
15
End credits
Vector balls morphing on the beat, Amiga style.
vector balls · shape morphing · bitmap font

How to read a page

Live. The scene's real shaders, ported line for line to WebGL2. Scrub the time, change the parameters.
Background. Short chapters, one idea each, with an interactive figure and a "Try:" hint.
Step by step. The full algorithm as pseudo-code, each step linked to the idea that explains it.
Source. The actual GLSL and C++ from the repository, plus a glossary of every term used.