You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
rust: Port the source audio render mix plan in obs-source.c to obs-source #2207
Port the source audio render mix plan in libobs/obs-source.c.h to rust/obs-source, as a new module audio_render_plan. These decisions move:
obs_source_audio_render: the route, which is one of no buffer, custom render, submix, or the tick.
custom_audio_render:
which mixes to clear before the callback;
the pending and timestamp result;
which mixes to clear after the callback.
process_audio_source_tick:
pending when there is no timestamp or not enough input;
for each of mixes 1-5, clear it or copy it from mix 0 (the submix case uses mix 1 only, with the mask forced to 1);
mix 0 is cleared when it is not in both masks.
These stay in C: the buffers and audio_buf_mutex, deque_peek_front, every memset/memcpy, the plugin callbacks, audio_submix, and apply_audio_volume (ported in #2175).
Plan (one PR, separate commits)
A behaviour-neutral move into libobs/obs-source-audio-render.c.h, as hidden functions.
Characterization in test_source_audio_render_steps. It covers:
every route;
the mixer masks at 0, 1, 0x3f and above, and UINT32_MAX;
the pending conditions at the size edges;
the submix case;
the callback's success and failure.
RED, then GREEN: the safe Rust core plus shims, in a libobs.ported-source-audio-render group. Exported symbols are unchanged.
Tier 3 parity against the original C: exhaustive over flags and masks, plus a proptest over full-range sizes and timestamps. Also a deliberate-break check and port_comparison numbers.
These real-libobs tests must stay green on every lane:
Activity
rdoupe commentedon Oct 24, 2026
Claiming: #2207.
libobs: Move the source audio render mix plan into obs-source-audio-r…
test: Characterize the source audio render mix plan
obs-source: Add Tier 1 tests for the source audio render mix plan port
obs-source: Port the source audio render mix plan
obs-source: Check the source audio render mix plan port against the C
docs: Record the source audio render mix plan port
obs-source: Port the source audio render mix plan (obs-rust#2254)