Skip to content

audio: an unlinked PipeWire output meters only what is sent to it - #2336

Draft
edumeneses wants to merge 1 commit into
masterfrom
edu/pipewire-unlinked-outputs
Draft

edumeneses wants to merge 1 commit into
masterfrom
edu/pipewire-unlinked-outputs

Conversation

@edumeneses

Copy link
Copy Markdown
Contributor

Bumps libossia to ossia/libossia#961 and adds its tests.

PipeWire gives no buffer to an output port that nothing is linked to, and libossia pointed every such output at one shared discard buffer. Nothing reads those ports, so nobody hears it, but the mixer's hardware output meters read the tick's outputs after the mix. Edu hit it testing the mixer (#2302) with score's PipeWire outputs unlinked:

  • a signal sent to /out/1 lit every channel's meter;
  • a stereo source showed on channel 3 as well.

libossia now gives each missing output its own scratch block.

Tests:

  • test_unit_pipewire_quantum: two missing channels get distinct scratch.
  • test_unit_pipewire_protocol_quantum: against a private daemon with no sink, three unlinked outputs each keep what the tick wrote to them. It fails without the libossia change.

The libossia pointer is #961's branch, merged with the commit master points at; it moves to libossia master once #961 lands.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Lc7tYGHRn6TmaxMEfBTswW

PipeWire hands no buffer to an output port that nothing is linked to,
and libossia pointed all of them at one discard buffer: a signal sent
to /out/1 showed on the meter of every unlinked output, and a stereo
source on a third channel too. libossia now gives each one its own
(ossia/libossia#961).

The PipeWire tests check that two missing channels get distinct
scratch, and, against a private daemon with no sink, that three
unlinked outputs each keep what the tick wrote to them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lc7tYGHRn6TmaxMEfBTswW
@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage is 48.526% — edu/pipewire-unlinked-outputs into master. No base build found for master.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants