Skip to main content

2D physics GPU test

JavaScript solves disc contacts while WebGL overdraws points with expensive fragment math. Watch CPU and GPU charts move together.

Rated 4.5 out of 5 based on 267 reviews

Your browser does not support the HTML canvas element.
Frame rate
--
FPS
Frame time
--
ms
Solver tier
--
Bodies
--
Substep slider
--
Contact iters / substep
--
Est. pair checks / frame
--
GPU point passes / frame
--
Framebuffer
--
Frame stability
--
%
Status
--

What this test measures

This is toy physics: circles, impulses, walls, and repeated contact solves. It exists to load the machine, not to ship in a game. The main thread pays for collision; the GPU pays for overdraw.

  • Low: fewer discs and fewer contact iterations.
  • Medium: a mid-scale pile.
  • High: largest population and heaviest per-substep solve.

Graphics adapter

Renderer
-
Vendor
-

How to run the physics test

  1. Start on Medium.
  2. Press Start and watch FPS plus stability.
  3. Raise the solver tier if you want more CPU work.
  4. Stop if the tab becomes unresponsive.

2D physics plus GPU points

Hybrid CPU solver and WebGL overdraw

CPU workIntegration and pairwise contacts
GPU workRepeated point drawing with heavy fragment math

What this physics test is for

Some devices fail on CPU collision before they fail on shaders. This page makes that split visible. The main thread solves disc contacts; WebGL overdraws points. It is not a volume shader BM test and not a production physics engine.

Phone and PC

Start on Medium. Raise the solver tier only if FPS stays even. A phone can stutter or freeze the tab at High. Stop if the device is uncomfortably hot or the tab becomes unresponsive.

Physics test questions

Why does the pile reset when I change the solver?
Changing solver tier respawns the bodies so the comparison starts from a known state.
Is this a 3D volume shader?
No. Open /tests/vsbm/ for the volume shader BM scene.
Can I run it on a phone?
Yes. Stay on Low or Medium. High can stall a mobile browser.
How do I read FPS here?
Watch FPS and stability together. If FPS falls when you only raise solver load, the CPU collision work is the likely limit.