Files
SirStone a79d809394 feat(m4): cap map images at Full HD and shrink on import (#85)
The owner fixed the map cap at 1920 px on the long side and 1080 px on the
short side (either orientation). fff-vtt import now shrinks a larger source
with ImageMagick Lanczos before tiling (alpha kept, proportions preserved,
no upscaling), prints `scaled WxH -> WxH`, and records the shrunk w/h; a
source at or below the cap is untouched, so the pixel-identity tests still
hold. A scene row already above the cap is not rewritten: the server logs
`map_above_cap` at startup and serve prints the re-import advice.

Docs: ADR-0023, DESIGN 3.3/5.3/8/11.1/13/14, TESTING 5.3/13, README,
HANDOFF-M4, client README. The M4 phone gate and the fogbench measurement
now use the Full HD maximum; the 16384 px / 262144-cell bench and test rows
stay as labelled server stress references. import-scale now proves a 16384²
input is shrunk to 1080x1080 (289 tiles at 64 px) quickly and bounded.

Part of #63, #85. #77 is blocked by this issue.
2026-11-21 22:37:34 +01:00

26 lines
1.8 KiB
Plaintext

== prototype scene (60 walls, 8 tokens, radius 400, cell 32) ==
1 poly (jittered start positions): n=2000 avg=0.020ms worst=0.873ms
6 polys (one 6-token party): n=500 avg=0.160ms worst=7.235ms
1 poly + cellsTouched (scanline): n=2000 avg=0.034ms worst=1.181ms
6 polys + cellsTouched (scanline): n=300 avg=0.187ms worst=0.349ms
1 poly + cellsTouchedOld (prototype reference): n=500 avg=0.849ms worst=2.251ms
TARGET polygon+cells, prototype scene (prototype baseline 0.451): 0.034 ms vs <= 0.451 ms: PASS
== 5k sparse (stress): genScene(world=16384., n=5000, seed=1), avg walls in vision bbox 15.6 ==
1 poly, 5k sparse (stress): n=2000 avg=0.058ms worst=0.197ms
1 poly + cellsTouched, 5k sparse (stress): n=2000 avg=0.061ms worst=0.169ms
1 move check (pathClear, cap-length step), 5k sparse (stress): n=20000 avg=0.009ms worst=0.245ms
TARGET polygon, 5k-wall stress scene: 0.058 ms vs <= 1.0 ms: PASS
== 5k dense (stress): genScene(world=4096., n=5000, seed=1), avg walls in vision bbox 206.9 ==
1 poly, 5k dense (stress): n=2000 avg=1.409ms worst=17.788ms
1 poly + cellsTouched, 5k dense (stress): n=2000 avg=1.712ms worst=16.250ms
1 move check (pathClear, cap-length step), 5k dense (stress): n=20000 avg=0.013ms worst=4.333ms
== egress (#28 stress: 6 players x 40 encountered entries, 262144 explored cells) ==
GM egress pass (fresh diff base): n=200 avg=0.586ms worst=1.199ms
player egress pass (fresh diff base): n=200 avg=0.188ms worst=2.470ms
== tile gate (#65): old SQL-under-lock path vs published snapshot ==
tile gate old: parse + SHA-256 + session JOIN + HashSet: n=2000 avg=0.014ms worst=0.582ms
tile gate new: parse + SHA-256 + cache lookup + bitmap: n=2000 avg=0.001ms worst=0.013ms
explored snapshot build (262144 cells): n=20 avg=3.606ms worst=4.623ms
explored incremental mark (16 fresh cells): n=5000 avg=0.002ms worst=0.765ms
(sink 24393102)