Expand description
Shared source decode pump.
One pump per job (not per rung): demux + decode the source once, run
the rung-agnostic per-frame work (4:4:4 → 4:2:0 downsample + HDR tonemap),
and fan the normalized frame out to N per-rung mpsc channels via cheap
VideoFrame::clone() (the inner Bytes is Arc-backed).
Per-rung scaling + encoding consume from those channels. Eliminating the redundant per-rung decode is the whole point — a 5-rung ladder decodes the source once, not five times. The cost: the slowest rung backpressures the pump (usually the largest rung, whose encoder is slowest).
Structs§
- Decode
Pump Config - Configuration for one decode pump.
Functions§
- run_
shared_ decode_ pump_ blocking - Blocking decode loop, designed for
tokio::task::spawn_blocking. Fans every normalized frame out to allsenders. If a sender’s channel is closed (its rung gave up) the pump continues with the rest; it stops only when every sender is closed.rtbridges into the asyncsend().await.