I am working on iPhone app that records a user voice. From time to time this game plays sounds using Unity3d engine. An Objective-C recorder should stop recording when it detects that unity engine plays the sound. Is there any way using OpenAL apis or Native iPhone SDK to detect the fact that the sound is currently playing on this device?
I have tried to send notification right from Unity after playing the sound
But still, sometimes it records a small chunk of sound. Any idea why it happens? I thought it would be much easier if I could detect on API level and block recording if device currently is playing audio, but I cant find such API.