Skip to content

gasmWrite a game once. Run it everywhere.

Games compile to one WebAssembly file. Small native and browser runners give them a stable interface for graphics, sound, input and networking.

gasm

What's inside ​

Runnersgasm-run: native (Rust: wasmtime, wgpu, winit, cpal, gilrs), with AOT compilation for no-JIT platforms. Browser runner: WebAssembly, WebGPU, AudioWorklet, Gamepad API. Headless Node runner.
GamesSumo: 3D two-player arena with lockstep netcode. NES: a complete emulator (tetanes-core) passing the blargg CPU, timing and APU tests. DOOM: doomgeneric in C, with OPL music and saves, playing any IWAD. ScummVM: point-and-click adventures, starting with the freeware Beneath a Steel Sky. SDL 3: SDL programs build unchanged, threads included; SDL's own snake and woodeneye demos. GLES 3: OpenGL ES code through drop-in headers. Triangle and test pattern: minimal examples in Rust and C.
Toolsgasm-relay (WebSocket rooms), the gasm-sdk Rust crate (library gasm), gasm.h and the C/C++ SDK, SDL 3 for gasm, cross-runner determinism and network test suites with golden hashes.

Screenshots ​

DOOM in gasm-run
DOOM (doomgeneric in C) with OPL music, at 4:3 with the sharp filter.
Beneath a Steel Sky in ScummVM
ScummVM playing Beneath a Steel Sky, upscaled with xBR.
Sumo, the 3D demo
Sumo: gasm:gfx (WebGPU) with lockstep netplay.
GPU texture test
Mipmapped textures, samplers, instancing and dynamic offsets on gasm:gfx.
GLES 3 test in the browser player
OpenGL ES 3 C code on gasm:gl, in the browser player (WebGL 2).
SDL 3 woodeneye-008
SDL 3's woodeneye-008, source unchanged, on SDL for gasm.
The same DOOM frame with the sharp, xbr, fsr and crt filters
One 2D frame, four ways to scale it up: sharp, xBR, FSR and CRT (the player's filter menu, gasm-run --filter).

Performance ​

Measured on an Apple M1 Pro. The NES emulator compiled to wasm runs at 1.5× (wasmtime AOT) and 1.6× (V8) the time of the same Rust code built natively. That's about 9× faster than the console itself. Sumo holds 60 fps with 4× MSAA on both runners.

Status ​

gasm is a proof of concept. ABI v0 is experimental and will change. See the roadmap: gasm:gl natively, rollback netplay, .gasm packages.

MIT licensed. The NES demo core is tetanes-core (MIT/Apache-2.0).