Skip to main content

HELD_KEY_BUDGET_S

Constant HELD_KEY_BUDGET_S 

Source
pub(crate) const HELD_KEY_BUDGET_S: f64 = 1.0;
Expand description

Seconds of a constant-rate target a held frame (the cleanup of a still screen) may spend: a held key frame larger than that is coded again at a coarser quantizer (held_key_retry), or planned with that budget where the library’s own rate control sizes it (x264, SVT-AV1), and a held refresh is coarsened to fit from the rate control’s last quantizer (pipeline::decide_hw_fullframe), and on NVENC coded again to fit where it comes out past HELD_REFRESH_LIMIT_S. A second of the target drains in 0.4 s at the pace the WebRTC pacer holds video to, so a user acting just as the cleanup goes out waits that long at most for it. It holds a 1080p key frame at the paint-over quantizer down to 2 Mbit/s (NVENC 144 kB, x264 182 kB); a quarter second made that key frame coarser than the picture it was cleaning (x264 52 kB at 31.7 dB, NVENC 99 kB at 45.3 dB at 2 Mbit/s).