use rear microphone of iphone 5
I have used to following code the stream the i/o of audio from microphone. What I want to do is want to select the rear microphone for recording. I have read that setting kAudioSessionProperty_Mode to kAudioSessionMode_VideoRecording can do the work but I am not sure how to use this with my code. Can any one help me in successfully setting this parameter. I have these lines for setting the property status = AudioUnitSetProperty(audioUnit, kAudioSessionProperty_Mode, kAudioSessionMode_VideoRecording, kOutputBus, &audioFormat, sizeof(audioFormat)); checkStatus(status); but its not working. in