Skip to content

libobs: characterize and extract obs_add_raw_audio_callback #5502

Closed

Description

@rdoupe

C-only prerequisite for the Phase 6 libobs core migration (#444): characterize obs_add_raw_audio_callback, then move it verbatim out of libobs/obs.c.h into one new libobs/obs-raw-audio-add.c.h, registered alphabetically in the core unity group (BUILD.md). It is the counterpart of obs_remove_raw_audio_callback, which went the same way (#4715, PR #4727; Rust swap #5003).

Add a new test_raw_audio_add cmocka test against both hybrid libobs and libobs-c-reference, through the public API only. Pin: a new mix/callback/param registers (observed synchronously through audio_output_connect's duplicate rejection and obs_remove_raw_audio_callback, no frame counts or sleeps); a repeated add of the same triple is a no-op; the same callback on another mix or with another param registers separately; an out-of-range mix_idx (including SIZE_MAX) registers nothing; a NULL conversion is accepted; the callback is connected to the initialized core's main audio output.

The only callee is the existing audio_output_connect; no helper or new seam. No change to existing C tests, public headers, workflows or plugins/obs-websocket. The Rust swap is a separate follow-up after this lands.

Open issue/PR search for obs_add_raw_audio_callback found no competing work.

Activity

  1. added
    port
    on Nov 23, 2026
  2. rdoupe commented on Nov 23, 2026

    @rdoupe
    CollaboratorAuthor

    Claiming: #5502

    1. Characterization: new test_raw_audio_add cmocka test, run against hybrid libobs and libobs-c-reference, plus a mutation check that it catches a broken add.
    2. Move obs_add_raw_audio_callback verbatim into libobs/obs-raw-audio-add.c.h, registered alphabetically in the core unity group. No behavior change.
    3. One PR, Refs libobs: characterize and extract obs_add_raw_audio_callback #5502; the Rust swap follows separately.
  3. added
    ready
    on Nov 23, 2026
  4. rdoupe commented on Nov 23, 2026

    @rdoupe
    CollaboratorAuthor

    Done in #5505 (merged): the characterization test and the extraction are on master. The Rust swap is #5511.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

portready

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions