Skip to content

Phase 2 follow-up: Implement full MediaStreamTrack constraint solver parity #68

@General-Fault

Description

@General-Fault

Current plan for #50 is staged delivery: native plumbing + marshalling + explicit failure paths, with full constraint solving deferred.

This follow-up tracks implementing full MediaStreamTrack.applyConstraints() parity behavior.

Problem

ApplyConstraints currently does not implement full constraint selection/fitness-distance solving behavior. Staged #50 intentionally defers full solver semantics.

Goal

Implement full constraints algorithm behavior aligned with W3C Media Capture and Streams and Google Blink/libwebrtc expectations, including:

  • Required vs ideal handling across MediaTrackConstraintSet and advanced
  • Candidate selection / fitness-distance style evaluation
  • Overconstrained-style failure semantics for unsatisfiable required constraints
  • Observable behavior parity for ordering and error surfaces

Scope

  • WebRtcInterop native/interop logic behind MediaStreamTrack::ApplyConstraints
  • Interop and managed tests validating solver behavior
  • Explicit documentation of any unavoidable .NET/runtime divergence

Acceptance criteria

  • Required constraints that cannot be satisfied fail deterministically with explicit error
  • Ideal constraints influence selection when multiple candidates satisfy required constraints
  • advanced sets are evaluated in order per spec processing model
  • Tests cover success paths, unsatisfiable required constraints, and ordering-sensitive cases

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions