Conversation
An endpoint whose routes are all unavailable, like an HDMI output with no display connected or a headset jack with nothing in it, looked the same as one that can play, labeled "No route selected". WirePlumber never selects an unavailable route, so these have no active route at all. Mark such endpoints unavailable in the view, list them after the rest, and patch their title, target and volume with a new node_unavailable theme style (dark gray by default, dim for nocolor). When the endpoint has a single route, show it as "<route> (unavailable)" instead of "No route selected". Endpoints without routes, such as Pro Audio nodes, are never considered unavailable.
A sink or source with no device, such as a filter-chain or null sink, has no routes, but it was labeled "No route selected" like a device endpoint that has lost its route. Label nodes with node.virtual set "Virtual" instead.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On laptops with a UCM card, each HDMI/DisplayPort output and the headset jack's microphone is its own endpoint, and wiremix lists them exactly like the ones that can play, labeled "No route selected". On mine the Output Devices tab shows four
sof-hda-dsprows, and only one of them has anything connected.WirePlumber never selects an unavailable route, so these endpoints have routes, all
available: no, and no active route. That availability is already inState, so this uses it:node_unavailabletheme style:DarkGrayindefault,DIMinnocolor, nothing inplain. They return to normal as soon as something is plugged in, since the view is rebuilt when the route changes.The second commit is independent and can be dropped: sinks and sources with
node.virtualset (filter-chain, loopback and null sinks) show "Virtual" instead of "No route selected", a label they shared with unplugged devices.Output Devices on 0.11.0, with headphones plugged in and a filter-chain sink:
With this branch (the last three rows are dimmed):
#58 covers endpoints with no routes at all, so the two don't overlap in behavior, though they touch neighboring lines in
Node::from. If you'd rather keep serial order, the sorting is one line and easy to make optional.Tested with new view tests (availability, ordering, target titles), the CI steps (fmt, clippy with
-D warnings, rustdoc with-D warnings), and against a live PipeWire 1.6.8 / WirePlumber 0.5.17 graph.