This plugin allows controlling the system value from a remote device.
- Group Reviewers
- Maniphest Tasks
- T4659: Add general system volume control to MPRIS controls using pulseaudio
- R224:02e52b787b8a: Add systemvolume plugin
Apply Android patch, open up MPRIS Activity and play with the slider
You can use pactl list sinks or pacmd info to get the current volume, but then you'll have to parse that information, unfortunately.
I got a working solution using pactl and some pretty ugly bash-magic. It works with a single audio sink but needs some adjustment to support multiple sinks.
Thanks, will take a look at it
Use libpulse. I copied the code from plasma-pa without modifying it. Most of it is unused, but *could* be
useful someday for more advanced features (e.g. switching profiles). I'm not sure how to deal with that. We
could strip down to the needed code, but then we could not apply improvements from plasma-pa easily.
One small bug I found: if the audio sink changes (eg: from pavucontrol I chose a different output), I have to close the MPRIS activity on Android and open it again for it to refresh. Very minor though, we can merge it unfixed.
Looks good. Is depending on PulseAudioQt okay already?
Do we need to check the packet type here? We already know it's destined for this plugin.
Needs a check to see if the requested sink still exists.
What happens if we already had that sink? Do we connect to this signal twice?
This code doesn't connect to the signals, so that's not correct, right?