Share one latest-frame slot between the camera capture backends
Author: AprilNEACreated Sep 19, 2026Updated Sep 19, 2026
Labelstype: enhancementplatform: linuxplatform: windows
capture_linux.rs and capture_windows.rs each define a private Shared holding the latest decoded frame behind a lock for the snapshot and stream paths; the macOS delegate keeps the same state on the ObjC side. The slot semantics — replace, take-latest, wake a waiter — are platform-neutral and belong in capture_types.rs next to Frame.
Deferred from the September refactor survey because neither backend can be run on this maintainer's host: the change needs a Linux and a Windows machine with a webcam to confirm the preview still streams and the snapshot still returns.
Source: AprilNEA/OpenLogi