Made an app on Unity that is recording from the microphone device, works fine on PC Windows, but when I test it on iPhone or Android, I see no recording device, the app is searching a recording device, on Android it can only find “Android Audio output” and on iPhone “Core Audio input”. And none of them is recording anything.
I thought it will be easier on mobile devices as they are used to record in the device very easily. You don’t have to plugin a microphone… so why is Fmod not working???
You need to make sure you have the appropriate permissions for recording in place. Please see our documentation for further information:
I checked the 2 links.
the iOS doesn’t show me a clear code of C# and where I should put it. There are simply not enough examples. Can’t find them in Google or anywhere else.
And the Android permission, I have added it, but nothing has happened, still no recording. here is the content of my AndroidManifest.xml file:
<?xml version="1.0" encoding="utf-8"?> <!-- GENERATED BY UNITY. REMOVE THIS COMMENT TO PREVENT OVERWRITING WHEN EXPORTING AGAIN--> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.unity3d.player" xmlns:tools="http://schemas.android.com/tools"> <uses-permission android:name="android.permission.RECORD_AUDIO"/> <application> <activity android:name="com.unity3d.player.UnityPlayerActivity" android:theme="@style/UnityThemeSelector"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> <meta-data android:name="unityplayer.UnityActivity" android:value="true" /> </activity> </application> </manifest>
this has solved my problem on Android:
On iOS it is still not working, even though on the xCode project I get from Unity of iOS I ask for permission to access the mic, though when I install the testing ipa on my iPhone, it doesn’t ask me for permission to use the microphone, The same on Android, even though I gave the app permission to use the microphone, which usually results in asking you permission during installation to use the mic, it doesn’t and only when I run the app it askes with the code shown in the link above, which would not be active unless it didn’t get permission during installation.
You have likely seen it but this doc gives more information on requesting permissions:
This is more of a Unity/iOS question for requesting permissions. I have consulted our development team and they suggest heading over to the Unity forums for this information.