GPU Terrarium

Four WebGPU compute simulations in one page: slime mold, reaction diffusion, flow field and galaxy collision.

Four WebGPU compute simulations you can switch between: slime mold, reaction diffusion, a flow field and a galaxy collision, each with restart and pause.

  • Three Houses

    One cottage drawn three ways: raw WebGL, raw WebGPU and Three.js, with a shared camera and the code for each shown.

  • Basic WebGPU Particles

    10,000 particles bouncing around, written as the smallest number of WebGPU steps.

  • 1 Million Particles

    A million particles simulated on the GPU every frame with WebGPU. Drag on the canvas to push them.

  • Self-Printing Code Block

    A code block that contains the code that drew it, with an explanation of the trick.