MusicPlayerDaemon / MPD

Music Player Daemon
https://www.musicpd.org/
GNU General Public License v2.0
2.2k stars 350 forks source link

OSX plugin output changes systemwide audio output device #881

Closed the-gingerbread-man closed 3 years ago

the-gingerbread-man commented 4 years ago

Description

The OSX plugin does not direct audio output from MPD to my external DAC as expected. Instead of "hogging" it, the hog_device property redirects systemwide audio output to the device. When hog mode is disabled, MPD outputs to the default system output rather than the device specified in its configuration.

Config (excerpt from mpd.conf)

audio_output  {
    type          "osx"
    name          "Schiit USB Multibit"
    hog_device    "yes"
    mixer_type    "none"
}

Expected Behavior

When hog_device is enabled, MPD should obtain exclusive access to the selected output device. System default output should not be directed to the device, and no other application should be able to access the device while MPD is running.

If possible, when hog_device is not enabled, MPD should still output to the selected device, but other applications and the system as a whole should be able to access the device as well. It should be possible to configure the system default audio output device independently.

Actual Behavior

When MPD starts, if hog_device is enabled, the system-wide audio output device is set to whichever audio device is specified in mpd.conf. If hog_device is not enabled, MPD outputs to CoreAudio and the default system output device. I am unable to change the system audio output device in Audio MIDI Setup while MPD is running in hog mode, but when MPD exits the system reverts to the selected output device.

Version

MacOS 10.15.4 (Catalina) running on a MacBook Air

Music Player Daemon 0.21.23 (0.21.23) Copyright 2003-2007 Warren Dukes warren.dukes@gmail.com Copyright 2008-2018 Max Kellermann max.kellermann@gmail.com This is free software; see the source for copying conditions. There is NO warranty; not even MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Database plugins: simple proxy upnp

Storage plugins: local nfs curl

Neighbor plugins: upnp

Decoders plugins: [vorbis] ogg oga [oggflac] ogg oga [flac] flac [opus] opus ogg oga [sndfile] wav aiff aif au snd paf iff svx sf voc w64 pvf xi htk caf sd2 [dsdiff] dff [dsf] dsf [hybrid_dsd] m4a [faad] aac [fluidsynth] mid [ffmpeg] 16sv 3g2 3gp 4xm 8svx aa3 aac ac3 adx afc aif aifc aiff al alaw amr anim apc ape asf atrac au aud avi avm2 avs bap bfi c93 cak cin cmv cpk daud dct divx dts dv dvd dxa eac3 film flac flc fli fll flx flv g726 gsm gxf iss m1v m2v m2t m2ts m4a m4b m4v mad mj2 mjpeg mjpg mka mkv mlp mm mmf mov mp+ mp1 mp2 mp3 mp4 mpc mpeg mpg mpga mpp mpu mve mvi mxf nc nsv nut nuv oga ogm ogv ogx oma ogg omg opus psp pva qcp qt r3d ra ram rl2 rm rmvb roq rpl rvc shn smk snd sol son spx str swf tak tgi tgq tgv thp ts tsp tta xa xvid uv uv2 vb vid vob voc vp6 vmd wav webm wma wmv wsaud wsvga wv wve [pcm]

Filters: libsamplerate soxr

Tag plugins: id3tag

Output plugins: null fifo pipe ao openal osx httpd recorder

Encoder plugins: null vorbis opus lame wave flac

Archive plugins: [bz2] bz2

Input plugins: file archive curl ffmpeg nfs

Playlist plugins: extm3u m3u pls xspf asx rss flac cue embcue

Protocols: file:// http:// https:// gopher:// rtp:// rtsp:// rtmp:// rtmpt:// rtmps:// nfs://

Other features: icu ipv6 tcp un

the-gingerbread-man commented 4 years ago

After rebooting, I had a different issue: MPD wouldn't connect to the external device at all, though it showed up in the Audio MIDI Setup device list. (Log message: May 30 00:29 : exception: Failed to read mixer for 'Schiit USB Multibit': unable to get volume: The operation couldn’t be completed. (OSStatus error 2003332927.)) Disconnecting the device and connecting MPD resolved that issue, but the problem described above remains.

MaxKellermann commented 4 years ago

In the bug reporting template, there was a section "Log" saying "Paste relevant portions of the log file here (--verbose)". You deleted it. Don't! Your bug report is incomplete and I cannot help you that way.

MaxKellermann commented 3 years ago

Closing due to lack of reply.