- Rewrote GIF LZW decoder (gif_parser.ts) — old version produced
wrong pixel indices for larger images (V20 QR frames), causing
all QR decodes to fail after GIF roundtrip
- Added full end-to-end test: encode → QR → GIF → parse GIF →
decode QR → RLNC decode → reconstruct (94 tests passing)
- Added GIF File input mode to receiver for debug/testing
- Fixed receiver stale closure bug (scanning state captured
as false, preventing any frame capture)
- GIF parser handles: LZW, interlaced, local/global palettes,
Graphics Control Extension, disposal methods
- Fix stale closure bug in camera capture loop (scanning state
captured as false, preventing any frame capture)
- Add GIF File input mode to receiver — upload a QR-over-GIF
directly to test the decode pipeline without camera
- Update decode worker to accept imageData or frameData
- Receiver now shows two input modes: Camera and GIF File
The rAF capture loop checked where
was a state variable captured in a stale closure.
The loop was created when scanning=false, so it immediately
exited on every frame and never captured any camera frames.
Fix: use scanningRef (useRef) instead of state for the loop
guard, so the rAF callback always reads the live value.