The battery pass: paint less, wake less
- opaque canvas: the compositor stops alpha-blending 2.5Mpx at 60Hz - settled modals and the death summary idle at 20-24 fps; play untouched - TUNE.lowPower caps RES at 3 (-44% pixels/frame), flippable live Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
911035af00
commit
3b6a82c97d
6 files changed
+43
-4
No files matched your search
+16
@@ -442,6 +442,22 @@ the countdown panel ('CHANGEOVER · RESUMING IN n'). He kept the burst-arm weapo
|
||||
praise words. **A bottom/above-rack message slot was proposed and REJECTED**: that is thumb
|
||||
territory — covered by the hand mid-pull and outside where the eyes are.
|
||||
|
||||
**Fifth batch, same day — THE BATTERY PASS.** "Drains battery like there is no tomorrow." Measured
|
||||
first: update() 0.01 ms, render() 0.15 ms per frame — the JS is nothing. The bill is fill-rate ×
|
||||
frame-rate (a 3x iPhone pushes a ~1080×2400 canvas through the compositor 60×/s) plus 60 Hz wakeups
|
||||
on static screens. Three levers shipped:
|
||||
- **The canvas is OPAQUE now** (`dom.js`: `getContext('2d', {alpha:false, desynchronized:true})`)
|
||||
— render() clears the whole frame to a solid colour anyway, so the compositor no longer alpha-
|
||||
blends 2.5 Mpx sixty times a second. Free.
|
||||
- **Calm states run slow** (`calmFps()` in main.js): a SETTLED modal (world frozen, only the blink
|
||||
moves) runs at 20 fps, the death summary once faded at 24. Live play stays at TUNE.fps — the 60
|
||||
was a feel decision and the governor deliberately never touches anything that moves.
|
||||
- **`TUNE.lowPower`** (>= 0.5, T-panel-flippable live): caps RES at 3 — −44% of pixels painted per
|
||||
frame, THE big lever. `RES` is `export let` now, re-derived in fitViewport; main.js re-fits when
|
||||
the knob flips. Sprites are 224px sources so RES 3 draws them at-or-below 1:1: softer, never
|
||||
mushy. OFF by default — whether the sharpness trade is worth it is Oliver's phone-call, and if he
|
||||
wants it player-facing it should become a settings toggle, not a TUNE knob.
|
||||
|
||||
**Fourth batch, same day — the card went HORIZONTAL, and nothing draws under a modal.** The
|
||||
stacked icon card ran 102 px tall and its lower third hung over live court; the icon sits LEFT of
|
||||
the text now (boxed to 58×52 so a wide tin cannot reach the type — and it draws BIGGER than the
|
||||
|
||||
Reference in new issue
Block a user