You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit d2641e1
Browse filesBrowse the repository at this point in the historyBrowse files
fix(demo): unify decode path + cache-bust wasm so the demo actually decodes
Two compounding bugs made every prior fix invisible in the live demo:
1. Duplicated decode logic. The WASM decode export and the CLI each carried a
hand-copied list of decoders that drifted: the CLI gained the new width-ratio
EAN edge reader while the WASM export still ran only the old quantized 1D path,
so the demo could never decode the curved/blurred 1D captures the CLI now reads.
Consolidated both into one library entry point, anyd::pipeline::scan_all(frame)
(2D samplers + EAN/UPC edge reader + quantized linear decoders, deduped). CLI
and WASM now call it, so a front-end can never again ship a stale decoder list.
2. No cache-busting on the wasm fetch. GitHub Pages + the browser cache .wasm
aggressively (and a blob worker's fetch ignores hard refresh), so visitors kept
running a stale build no matter what was deployed. The page now loads
anyd.wasm?v=<load-time>, shared by the main thread and the decode worker.
Verified via scan_all on the exact crops the demo produces from real captures:
the curved bottle EAN-13 (4901085663356) and a hand-held omron QR both decode.
Adds testdata/real_scene_qr.png + real_scene_qr_via_scan_all pinning the shared
path. Full suite / clippy / fmt / doc clean.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0 commit comments