Explain the possible frame rate in the performance overlay (#275)
- Concepts: what the Possible line shows and why it is an upper bound - Architecture: how possibleFps is computed - Development: the e2e total is 1602 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent
9d65087c79
commit
6413fa595f
3 files changed
+8
-2
No files matched your search
+2
-1
@@ -363,7 +363,8 @@ ticks with `performance.now()`; `PlaySession` sorts them into behaviors, physics
|
||||
`GameViewport` adds up what its `redraw` takes, and `ui/render.ts` keeps what the last
|
||||
`app.render()` took (`lastRenderTime`). Both together are *Drawing*. `Editor.tick` times itself;
|
||||
what is left of that once the systems and the game's redraw are taken off is *Editor*. The meter
|
||||
averages per frame over 0.5 s, the window of the fps readout. The released game leaves
|
||||
averages per frame over 0.5 s, the window of the fps readout. *Possible* on top is
|
||||
`possibleFps`: 1000 ms over the sum of the five areas, rounded down. The released game leaves
|
||||
`timeSystem` unset, so the world runs untimed there. Browsers round `performance.now()` (Chromium
|
||||
to 0.1 ms without cross-origin isolation), which the average over some 30 frames smooths out.
|
||||
|
||||
|
||||
+5
@@ -109,6 +109,11 @@ averaged over half a second:
|
||||
| **Drawing** | Building the game's picture and handing the frame to the GPU |
|
||||
| **Editor** | Everything else the editor does in the frame: writing the run into the model, the panels, the console |
|
||||
|
||||
The top line, **Possible**, is the frame rate the measured time would allow if nothing waited for
|
||||
the display: a second divided by the five times added up. The frame rate below it stops at the
|
||||
display's rate (60 on most screens), this one does not. Because the GPU's time is not in it, it is
|
||||
an upper bound, and the editor's share is in it, so a released game can do a little better.
|
||||
|
||||
A dash stands for what has not been measured yet, in the first half second of a run. The numbers
|
||||
are what the main thread spends; the GPU works on after that, and its time is not in them. The
|
||||
switch is not saved and stays as it is until the page is loaded again. A released game has no
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@ php tests/php/accounts.test.php # the API's accoun
|
||||
# has and the web server's container has not (SKIP there)
|
||||
php tests/php/snapshots.test.php # the snapshot store (#231), the same way
|
||||
php tests/php/releases.test.php # the release store (#266), the same way
|
||||
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1601 editor checks, screenshots in /tmp/gm-e2e-*.png
|
||||
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1602 editor checks, screenshots in /tmp/gm-e2e-*.png
|
||||
GM_STEPS=20 node tools/e2e.mjs # or 1-12, or 6,20 — a subset while working on one step
|
||||
./e2e.sh start [GM_STEPS] # the same run detached, see below
|
||||
./e2e.sh status # live progress, or the last run's result
|
||||
|
||||
Reference in new issue
Block a user