There seems to be a problem on iOS7 devices where background-foreground switching of the application causes disappearance of audio.
We believe that this might have something to do with Fmod Ex.
Interesting effect: when the audio has been lost, it is played back during the animation from fg -> bg (you get to hear some brief 0.5s part of sound, but after that it’s lost)
Any help is very welcome!
Kind Regards, Aki Latvamäki
- alatvama asked 5 years ago
I was wondering could this have something to do with the FMOD_IPhone_RestoreAudioSession function? We call that in our in our applicationWillEnterForeground method. I searched through the examples provided with fmod ex and didn’t see it there.
I was looking through the change log and loticed this line in the 4.35.0 release notes:
– iPhone – Fixed audio not coming back after screen lock and when background
audio is interrupted with iOS 4.2. RestoreAudioSession function
is no longer required.
Is the restore audio session call necessary and could it be the culprit of our sound dissappearing problems?
If you are using a recent version of FMOD then the FMOD_IPhone_RestoreAudioSession function does not do anything, its use has been deprecated.
A repro of this behavior would be ideal to help us debug, but I also have a few questions:
- Are you using the background audio feature?
- Which session category are you using?
- Are you using any AudioSession native APIs?
Thanks for the info. We are using the latest stable version. I was pretty sure that FMOD_IPhone_RestoreAudioSession doesn’t do anything but I wanted to be sure.
This bug seems to be extremely hard to reproduce. We have seen it couple of times with one of our own development iPads but it went away after an update. Now that our game has gone live we have gotten reports of total loss of sound from our users.
The answers for your questions:
Are you using the background audio feature?
No. Our game plays audio when it is on the foreground.
Which session category are you using?
We’re using FMOD_IPHONE_SESSIONCATEGORY_MEDIAPLAYBACK.
Are you using any AudioSession native APIs?
No. All audio is played with FMOD
Please login first to submit.