retroglyph ← Back

Interactive Demos

Demos running in the browser via WebAssembly.

Example Headless Terminal Software WebGL WebGPU
01_hello_worldRunRunRunRunRun
02_colorsRunRunRunRunRun
03_keyboardRunRunRunRunRun
04_mouseRunRunRunRunRun
05_layout_gridRunRunRunRunRun
06_layersRunRunRunRunRun
07_sprites_tilesetRunRunRunRunRun
08_animationRunRunRunRunRun
09_widgets_dashboardRunRunRunRunRun
10_widgets_interactionRunRunRunRunRun
11_sokobanRunRunRunRunRun
12_dungeon_scrollRunRunRunRunRun
13_combat_logRunRunRunRunRun
14_resizeRunRunRunRunRun
15_outpost_dashboardRunRunRunRunRun
16_subcell_imageRunRunRunRunRun
17_theme_switchRunRunRunRunRun
18_text_alignRunRunRunRunRun
19_weighted_fillRunRunRunRunRun
20_overworldRunRunRunRunRun
21_text_inputRunRunRunRunRun
22_random_tilesRunRunRunRunRun

Headless renders as plain text (a fixed-size character grid, no canvas) — the same Headless backend used in tests, driven here by a browser requestAnimationFrame loop and an on-screen button toolbar. Terminal (via xterm.js) renders real ANSI/SGR escape codes — the same terminal-family renderer the native crossterm backend uses. Software is the CPU-rasterized pixel backend, rendered to a <canvas>. WebGL is the GPU backend (retroglyph-gl) running on WebGL2 — the same instanced-quad renderer the native OpenGL 3.3 backend uses, rendered to a <canvas>. WebGPU is the newer GPU backend (retroglyph-wgpu), the same one that runs on Vulkan, Metal and D3D12 natively. It needs a browser with WebGPU (Chrome/Edge 113+, Safari 26+, or Firefox with dom.webgpu.enabled) and says so rather than showing a blank page if that's missing; it also starts blank for a moment while it acquires a device asynchronously. Every example gets all five variants (see tools/build-wasm-examples.sh) — there's no per-example backend list to keep in sync.