Standalone Plugin always asks for microphone access on macOS

Standalone Plugin always asks for microphone access on macOS. I’ve set my channel config to {0,1} and {0,2}, yet my standalone plugin can still configure the input and asks for permission when you start it. Any way to work around this?

1 Like

Someone can correct me if I’m wrong, but I believe you need to use the explicit new channel configuration (.withOutput), not the old {0,1} stuff. To the best of my knowledge, the current standalone wrapper checks that to trigger the microphone access.

(Honestly, I’m not sure why the JUCE team don’t just remove the old channel config. It is too basic for modern use cases.)

3 Likes

That did it, thanks.

I’m an in the situation that the Standalone Plugin does NOT ask for a permission (Mojave), therefor I cannot get any microphone input. Is it a bug, does the Standalone Plugin, with the latest SKD needs some kind of flag, so it will ask?

Okay, problem solved, added Microphone Access in Xcode Exporter in Projucer

Do you know how to make the standalone app ask for microphone access when compiled with CMake? I’ve tried with the following lines in my CMakeLists:

juce_add_plugin(XXX
# VERSION 1.0                               
# ICON_BIG ...                             
# ICON_SMALL ...
COMPANY_NAME XXX                           
IS_SYNTH FALSE                              
# NEEDS_MIDI_INPUT TRUE/FALSE               
# NEEDS_MIDI_OUTPUT TRUE/FALSE              
IS_MIDI_EFFECT FALSE                        
# EDITOR_WANTS_KEYBOARD_FOCUS TRUE/FALSE   

MICROPHONE_PERMISSION_ENABLED TRUE
MICROPHONE_PERMISSION_TEXT "Need access to your audio interface" 

COPY_PLUGIN_AFTER_BUILD TRUE                
PLUGIN_MANUFACTURER_CODE XXXX               
PLUGIN_CODE XXXX                            
FORMATS AU VST3 Standalone               
PRODUCT_NAME "XXX")  

(I’ve put the “X” just to cover personal data). Not only this does not enable the microphone, but also seems to stop my standalone plugin from reading files in the document folder (I need some files that are placed there, if I compile without MICROPHONE_ flags it works). Also the plugin crashes when I close it (again, without that flags this problem was absent).

So, what is the correct way to access the microphone/audio interface on macOS in a standalone version of a plugin?

I reply to myself:

That is the correct way to do it, but after that addition you have to completely clean the build folder and rebuild the project. Now it works perfectly.

2 Likes

I’m having the same issue with a standalone gui app however there’s nowhere in the projucer that I can set the channel configuration that I see. How can I solve this?