Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can you get this working without microphone access? #177

Open
ugultopu opened this issue Dec 14, 2018 · 6 comments
Open

Can you get this working without microphone access? #177

ugultopu opened this issue Dec 14, 2018 · 6 comments

Comments

@ugultopu
Copy link

ugultopu commented Dec 14, 2018

In Mojave, the application doesn't work without microphone access. I think this is related to #163 and 75e8d5c. I don't understand why this application might need microphone access, while all it's doing is with speakers. Maybe it's Mojave's application permission system developers' fault, for wrongly naming "audio system access" as "microphone access".

@kyleneideck
Copy link
Owner

It's weird, I know, but Background Music does actually need that permission, at least for now.

BGMDriver (the audio driver part of Background Music) creates a virtual output device, which receives your system's audio, and a virtual input device, which plays back the same audio. BGMApp (the app part of Background Music) gets the audio from the virtual input device and then plays it through your real audio device. The virtual input device can also be used to record your system's audio.

Technically, the "microphone access" dialog is asking for permission to access input devices, so BGMApp can't use the virtual input device without that permission.

There are other ways to send the audio to BGMApp, shared memory using XPC for example, but using a virtual input device was easier at the time. I've wanted to try using shared memory for a long time to see if it could help reduce latency and CPU use, and getting rid of the confusing microphone access dialog would be nice as well.

@mbakkokom
Copy link

Hello, I just found your amazing software today and I love it!

Unfortunately, first running it on macOS Mojave (10.14.4) without microphone access would render it unusable. I was unable to play anything through Background Music until I allow microphone access.

I installed it through Homebrew (Background Music 0.2.0) if you're wondering.

Is there any workaround for this? I don't really need to manage my audio through Background Music. I just want to manage application volumes.

Thank you anyway!

@weeebdev
Copy link

image

btw it shows the app in the menu as if it's using mic. Kinda misleading

@burckaansen
Copy link

Hi,

I have the same problem and when I disabled the mic permission the app didn't work
Screenshot 2023-04-12 at 00 56 19

@githubjsorg
Copy link

BGMDriver (the audio driver part of Background Music) creates a virtual output device, which receives your system's audio, and a virtual input device, which plays back the same audio. BGMApp (the app part of Background Music) gets the audio from the virtual input device and then plays it through your real audio device. The virtual input device can also be used to record your system's audio.

That would explain the noticeable degradation in the audio. Or maybe it just doesn't work well in Ventura or on the new M2 systems?

image

Is there any other (better) way to do this? It sounds like quite a trip for the audio to take through 3 virtual devices.

@AurimasBalciunas
Copy link

AurimasBalciunas commented Oct 22, 2023

@githubjsorg I haven't tried Background Music, but I made a similar Virtual Audio Device to record system audio and I found that I could maintain high quality audio from my main output by setting up a multi-output device in Audio Midi Setup that outputted both to the virtual audio device and my desired audio device. I am looking through the BM code right now, but if it is actually forwarding music to the output device maybe you can disable that and create a multi-output device instead

Granted, this renders background music largely useless unless you are using it solely for the ability to record system audio

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants