src.nth.io/

summaryrefslogtreecommitdiff
path: root/main/viewport_state.h
diff options
context:
space:
mode:
authorLuke Hoersten <[email protected]>2026-06-20 13:27:42 -0500
committerLuke Hoersten <[email protected]>2026-06-20 13:27:42 -0500
commite5acf936ea641c88c10bf50862602289235ae888 (patch)
tree7e0daa569313f37f1ca7ed4c7ec7a2222b1ba9e0 /main/viewport_state.h
parent175dd50ba2a2a6c8d033a9fd4e91f4823f9e210a (diff)
scrypted: skip-oldest backpressure on stream socket
Hold at most one pending frame; new ffmpeg frames arriving while the socket is backpressured replace the held one (drop oldest) instead of queueing. On 'drain', flush the held frame. The in-flight write stays out of our hands. Steady-state Node-side buffer drops from up to 20MB to ~1 frame, eliminating the cap-and-reconnect loop as the primary shedding mechanism — it's now an emergency safety net for stuck connections that never fire 'drain'. Capture-time timestamp instead of write-time so a held frame keeps its true age and g2g reflects any pending-slot hold latency. New log fields: drop-oldest=N (frames shed from the pending slot this window) and bp=N% (share of ffmpeg frames in the window that found the link backpressured at decision time).
Diffstat (limited to 'main/viewport_state.h')
0 files changed, 0 insertions, 0 deletions