• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Changing buffer size on iOS when app is in background
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Changing buffer size on iOS when app is in background


  • Subject: Changing buffer size on iOS when app is in background
  • From: Daniel Blezek <email@hidden>
  • Date: Fri, 11 Feb 2011 11:14:44 -0600

Hi all,

  I'm very new to Core Audio and have been having playback issues on
the iOS.  My sound is fine while the app is in the background,
however, after the app is sent to the background and restored to the
foreground, the audio becomes very choppy.  Some helpful posts on the
Apple dev forums pointed out that iOS increases the buffer size when
an app goes to the background, presumably to increase battery life.
My app doesn't catch this, and continues filling up only part of the
buffer, so my audio is choppy and sounds stretched.

  The most simple thing would seem to be to register a callback for
this change, and reset the buffer size to what the app is expecting (I
don't play audio while in the background).

  I think the property is kAudioQueueProperty_DecodeBufferSizeFrames,
but I have not found any example code or good documentation on how to
use this.  Can someone point me to an example or documentation?

Thanks much,
-dan

P.S.  The original forum discussion is here:
https://devforums.apple.com/thread/85762?tstart=0
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Changing buffer size on iOS when app is in background
      • From: Steve Bird <email@hidden>
  • Prev by Date: Core Audio driver compatibility
  • Next by Date: Re: Changing buffer size on iOS when app is in background
  • Previous by thread: Re: Core Audio driver compatibility
  • Next by thread: Re: Changing buffer size on iOS when app is in background
  • Index(es):
    • Date
    • Thread