Historical recipe — not current setup guidance. Measurements and implementation links below belong to their original workload and revision. Deployment labels and defaults may be obsolete. Use the reviewed performance recipes; browse historical evidence.

AVPlumber · Mixer optimization cookbook

One reference frame for monitor encoders

Implementation links are pinned to develop at c20464a5 (2026-10-09). The mixer has changed since; this page was checked against develop at 8fa15c92 on 2026-10-13. Measurements retain their original workload and scope. Watch the current 192-input L4 demo.

Current scope. AUX rendition defaults use dpb_size: 1, including additional buses. The two-monitor memory example below is historical; it is not the saving for every possible output count. Program and clean-feed settings are separate.

The monitor encoders, one per AUX bus, keep one reference frame instead of the several NVENC reserves by default, because without B-frames each frame is predicted from the previous one. Measured on an NVIDIA L4 on 2026-10-14: an H.264 1080p p3 encoder with the AUX settings holds about 48 MiB with NVENC's own choice and about 34 MiB with dpb_size 1.

Status: Implemented

The idea

An H.264 frame is coded as the difference from earlier frames. The encoder keeps those earlier frames, reconstructed, in its decoded picture buffer (DPB). With dpb_size 0 (automatic), NVENC reserves room for several of them. The mixer's streams use no B-frames and no lookahead (ultra-low-latency tune), so each frame references the previous one. The other slots sit in VRAM.

With dpb_size 0 NVENC keeps several reference slots but frame N uses only frame N−1; with dpb_size 1 only that slot remains and the rest of the memory is freed. dpb_size 0 NVENC decides N−4 N−3 N−2 N−1 encode N Reserved slots, in VRAM. Almost never used as a reference. dpb_size 1 monitors only freed: about 14 MiB per encoder (measured) N−1 encode N Same reference, same encode order, same timing. Frames still leave the encoder one at a time, as they are made.
Blue is the reference frame N actually uses. Hatched slots are reserved but idle. The slot count under dpb_size 0 is illustrative: NVENC picks it. The saving was measured later: about 14 MiB per 1080p H.264 encoder on an L4 (48 against 34 MiB, one encoder fed by one raw source, per-process GPU memory).
Program and clean encoders keep dpb_size 0; the Program preview and Multiviewer monitor encoders get dpb_size 1. What viewers see · untouched Program encoder dpb_size 0 (NVENC decides) Clean feed encoder dpb_size 0 (NVENC decides) Monitors · changed Program preview aux dpb_size 1 Multiviewer aux dpb_size 1 Aux buses default to 1; any rendition can override it with "dpb_size".
Only the operator monitors change. The encoders viewers receive keep NVENC's own choice.

At a glance

Where in the code

Source links identify the reviewed code, independently of deployment state.