This is a weird one. I did a release recently using XCode 5 to support iOS7.
Now, I’m getting several reports that game-audio is coming out of the tiny ear speaker on the top front of the phone (The speaker used when on a phone call) instead of the larger speakers on the bottom of the phone.
I think most the reports are from people with iPhone5s but can’t confirm.
I’m not purposefully using the microphone, but possible I enabled it by accident during deploy. I’ll did around XCode and see if I accidently enabled it.
Thanks for the fix… will give that a shot if I can’t fix it in XCode.
We have the same problem, but where wondering if this fix forces audio to the speaker EVEN when a headphone is plugged in?
Our app is allready on the appstore and need to fix this ASAP.
I also have same problem. I have Unity 4.5.2 installed and Xcode 5.1.1. What is weird is that this worked fine a couple a days ago. So is it unity or xcode or ios that is the problem ??.
Hi all. I also had the problem and I was able to resolve it by unchecking “Prepare iOS for recording” in the Player Settings. I am using Unity 4.6.0p1
Please verify if it works for you as well.
is not working any idea? seems was not working in xcode 7
got this error from cloud build
[xcode] /BUILD_PATH/samwit.watson-space-01.default-ios-5-3-1f1/temp.C5fLMz/Libraries/Plugins/iOS/iPhoneSpeaker.m:34:11: error: cast of C pointer type ‘CFStringRef’ (aka ‘const struct __CFString *’) to Objective-C pointer type ‘NSString *’ requires a bridged cast
That’s an easy fix, just make it a bridged cast in xcode.
The problem I’m having is that if you do this while there are headphones plugged in, and then unplug the headphones, the sound still comes through the ear speaker. Any clues?
It appears to be a unity <?> bug - not sure if anyone has reported as such.
The way around it is at the start of a scene (or when you implement audio) to put into the code:
using UnityEngine.iOS;
if((Device.generation.ToString()).IndexOf("iPhone") > -1){ //for iphones only
iPhoneSpeaker.ForceToSpeaker ();
}
information devices : iphone 6s ios 12 , Samsung "android 7 ".
unity version : 2018.2.12f1.
i tried speaker script is work fine with my iphone , but still there is problem
the problem is : microphone not work i don’t hear anything in anther device !