Post

Replies

Boosts

Views

Activity

Reply to It's not possible to pause playback using bluetooth headset after setting MPNowPlayingInfoPropertyPlaybackRate > 1.0
Hello! We just ran into a similar issue with the "pause" command not working for bluetooth controls when the speed is >1.0. The solution was to set MPNowPlayingInfoPropertyDefaultPlaybackRate on MPNowPlayingInfoCenter. This was really only clear after reading the source headers: // The "default" playback rate of the now playing item. You should set this // property if your app is playing a media item at a rate other than 1.0 in a // default playback state. e.g., if you are playing back content at a rate of // 2.0 and your playback state is not fast-forwarding, then the default // playback rate should also be 2.0. Conversely, if you are playing back content // at a normal rate (1.0) but the user is fast-forwarding your content at a rate // greater than 1.0, then the default playback rate should be set to 1.0. @available(iOS 8.0, *) public let MPNowPlayingInfoPropertyDefaultPlaybackRate: String // NSNumber (double) Apparently AVPlayer thought that the app was fast-forwarding because this rate did not match MPNowPlayingInfoPropertyPlaybackRate. Keeping those in lockstep fixed the bluetooth controls for us.
Mar ’22