If Apple Music is playing when my app starts up and I define the category - Apple Music pauses.
If I start Apple Music after my app is running, I get Apple Music to duck while my audio plays, but Apple Music remains ducked after my audio completes. * try audioSession.setCategory(AVAudioSessionCategoryAmbient, with: [.duckOthers])* I would assume that the audio would come back up. And wouldn't think my app would pause Apple Music when it starts up... On Fri, Aug 18, 2017 at 1:34 PM Quincey Morris < quinceymor...@rivergatesoftware.com> wrote: > On Aug 18, 2017, at 10:10 , Eric E. Dolecki <edole...@gmail.com> wrote: > > > try audioSession.setCategory(AVAudioSessionCategoryPlayback, with: > [.allowBluetooth, .mixWithOthers]) > > > According to the documentation, AVAudioSessionCategoryPlayback will > “interrupt” other audio that *doesn’t* have the mixWithOthers option, and > this is defined here: > > > https://developer.apple.com/library/content/documentation/Audio/Conceptual/AudioSessionProgrammingGuide/HandlingAudioInterruptions/HandlingAudioInterruptions.html > > That makes it sound like it’s up to the *other* application to resume > after an interruption, and it’s not under your control. What’s odd is that > the first table here: > > > https://developer.apple.com/library/content/documentation/Audio/Conceptual/AudioSessionProgrammingGuide/AudioSessionCategoriesandModes/AudioSessionCategoriesandModes.html > > says this behavior can be changed by an “override switch” without saying > what that means. This page: > > > https://developer.apple.com/library/content/documentation/Audio/Conceptual/AudioSessionProgrammingGuide/AudioSessionBasics/AudioSessionBasics.html > > suggests that it might mean the category options, but it’s not clear. Have > you tried the “duckOthers” option, as well as or instead of “mixWithOthers”? > > _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com