Skip to content

rust: port obs_source_reset_settings to obs-source #5785

Not planned

Description

@rdoupe

Port the public obs_source_reset_settings() from libobs/obs-source.c.h into obs-source. It is the reset the properties dialog's Defaults button and the scripting obs_source_reset_settings binding use; no cmocka test calls it today.

Contract to keep (pinned by a new cmocka characterization against hybrid libobs and the C reference):

  • Invalid source: the usual obs_source_valid log (obs_source_reset_settings: Null 'source' parameter, LOG_DEBUG), nothing cleared or updated.
  • Otherwise obs_data_clear(source->context.settings) first, then obs_source_update(source, settings) with the caller's settings as given (NULL included), in that order, the source's settings object kept (same pointer).

Plan: extract the entry verbatim into its own file in the live libobs.core-source group, characterize, Tier 1 RED against todo!(), then the Rust swap through a small field adapter (the settings pointer, clear, update), a Tier 3 differential against the original C, and Tier 2 unchanged. No public-header, existing-C-test, WebSocket or workflow edits. Tier 4 does not apply.

Activity

  1. added
    enhancement
    port
    on Nov 26, 2026
  2. rdoupe commented on Nov 26, 2026

    @rdoupe
    CollaboratorAuthor

    Claiming: I'll extract, characterize and port it, RED then GREEN, in one PR.

  3. rdoupe commented on Nov 26, 2026

    @rdoupe
    CollaboratorAuthor

    /ready

  4. added
    ready
    on Nov 26, 2026
  5. rdoupe commented on Nov 26, 2026

    @rdoupe
    CollaboratorAuthor

    Duplicate of #5718, which zackees already claimed and has in progress (#5730). Releasing my claim.

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

Metadata

Metadata

Assignees

Labels

enhancementportready

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions