- Home /
Mac Built-In Microphone Not Working
So I put in the following code and it returns nothing. The list of available microphones is empty. I have a new macbook pro retina, and i tested the microphone, it is working, the "Built-In" microphone device is the one that is active... is there something I'm missing? Has anyone else encountered this?
string[] devs = Microphone.devices;
foreach(string s in devs) {
print (s);
}
,
I've also come up with this issue. Did you have any luck solving it?
Answer by kkiniaes · Apr 19, 2014 at 03:00 PM
So I figured out the problem. It has to do with the permissions and being able to access the microphone. Even on standalone unity games, you have to ask the user for permission to use the microphone.
https://docs.unity3d.com/Documentation/ScriptReference/Application.RequestUserAuthorization.html
Check the documentation here to see how to do that. If you basically copy the code on that site then at the beginning of the game, a popup should appear asking the user permission to access their microphone. I did this and my game works just fine now.
Answer by ceo1207 · May 10, 2016 at 05:54 AM
to get authorization of microphone using Application.RequestUserAuthorization may not help this problem.you only need to call this function when the project target is a web player.
maybe change configuration of your microphone and reboot.it may help you solve this problem.
and can you add more details of this problem. Microphone.devices return null or return value but it is empty.
i encount this problem in my machine(win 7 sp1).i can get Microphone.devices,but it is empty. i change the configuration of microphone and reboot.it works well finally.