AVAudioPlayer not stop automatically when enter background in iOS 8.2~8.3 - ios

Our app play some sounds. But we don't want to play in background.
We found only iOS 8.2~8.3 won't stop sound when app enter background.
Is this a bug or AVAudioPlayer have changed in iOS 8.2~8.3?

Finally found this is a bug with simulator from iOS 8.1 ~ 8.3.

Related

AVSpeechSynthesizer ignoring mute switch on iOS 13

Any AVSpeechSynthesizer utterance on iOS 13 ignores the mute/silent switch and plays the audio through the device's speakers. I thought maybe I had some weird audio setting in my app that was causing this, but I just tried creating a demo app that does nothing but play an AVSpeechSynthesizer utterance and it ignores the mute switch as well. Has anyone found a workaround for this?
EDIT: This was fixed in beta 5.

Background audio not work with Ionic3 + Videogular2 on iOS

I'm using Videogular2 in an Angular/Cordova/Ionic3 project, where I play mp3 audio live streams. All works good with mp3 and mp4, on browser and iOS simulator.
When the user Lock The Screen in iOS Device I expect that the audio continues to play in a background mode, but on IOS when the user Lock The Screen audio stop to play.
I've tested on XCODE 8 to set 'Capabilities' tab adding 'audio' parameter, I've added cordova-plugin-backgroundaudio to the project without success.
On iOS Simulator it works well, the problem occurs only on iOS Device.
Tested on iPhone 6 & iPad 3.
I'm using:
iOS 10.3.3
XCODE 8.3.3
Ionic 3.12.1
Videogular2 5.4.11
No one else used videogular2 on cordova/ionic?
In iOS app audio won't be playing in background when the device is locked. For that you have to enable the background mode for the app. I had faced the same issue in one of my application (I was using different audio plugin).
In order to enable background mode in iOS you can use below plugin
https://ionicframework.com/docs/native/background-mode/. When you start playing the audio you just need to call backgroundMode.enable() to keep it playing in background. When you leave the audio player page if want you can disable background mode to avoid unnecessarily keeping the background mode on by calling backgroundMode.disable().
Additionally you need to enable the background audio feature in xcode project settings as shown in below link.
https://koenig-media.raywenderlich.com/uploads/2016/09/BM-EnableAudioInBG.png

AVPlayer pause live stream on iOS 9.3

Im having difficulties trying to resume live stream playback from previously paused moment.
On iOS 9.2 and below player continued to play from paused moment.
On iOS 9.3 and above, when i resume playing, i receive "playerBufferEmpty" and AVPlayerItemTimeJumpedNotification, and as a result playback doesnt continue from the paused moment.
This looks like an issue in AVPlayer since everything works on iOS versions 9.2 and below. I also tried playerItem.canUseNetworkResourcesForLiveStreamingWhilePaused , but it doesnt help.
Are there any changes in AVPlayer/AVPlayerItem regarding this from iOS 9.2 to iOS 9.3?
Thanks!

Can app tested in iPhone run in background?

I write an audio player app with Xcode 6 in iOS 8. The problem is, when the audio player runs in iOS simulator, it can play audio in background, but when I test it in the real iPhone device, it cannot play audio in background. I wonder if Apple has limitation in testing in real iPhone device or I make some mistakes in settings.

Music plays when volume turn off

I have next issue:
I use AudioServicesPlaySystemSound to play short sound in my app. But something happens wrong: when I turn off volume on the device - sound still playing.
I found this issue on devices with iOS 6.0 and greater. On iOS 5 device all right.
Can anybody point me what I do wrong?
Thanks.

Resources