• 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
Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning


  • Subject: Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
  • From: Craig Hopson <email@hidden>
  • Date: Tue, 30 Sep 2008 11:34:59 -0600

Not to put too fine of a point on it, but calling AudioQueueStop( xxx, false ) MAY cause the queue to stop before the function returns. In my application I initially tried to dispose of the queue upon returning from this call and maybe 1 out of 20 times crashed because the queue was still busy. I now always rely on the _isRunning property - it's just safer.

-Craig

On Sep 30, 2008, at 9:53 AM, Doug Wyatt wrote:


On Sep 28, 2008, at 16:15 , John Zorko wrote:
1. When is kAudioQueueProperty_isRunning set? Is it set when there are no more buffers to play, or after I call AudioQueueStop()?

set after you start and the hardware actually starts cleared after you call AudioQueueStop...

3. How _exactly_ does the boolean parameter for AudioQueueStop() work? The documentation seems to say that setting it to true makes the call synchronous i.e. it won't return until the audio queue has played (and thus emptied) all of its' buffers. If I set it to false, the documentation seems to say that it's async, and I need to wait for the kAudioQueueProperty_isRunning property to be set to false. Is this correct, or am I confusing this boolean param with this property?

inImmediate=false: the call is asynchronous. The queue will not actually stop until everything you have enqueued has been played. You will receive an IsRunning notification shortly thereafter.


inImmediate=true: the queue will stop immediately. You will get an IsRunning notification very soon.

Sorry, the tech writer belabored the distinction a bit confusingly and we didn't catch it. All "synchronous" is meant to imply is that stopping will happen before the function returns.

_______________________________________________
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


_______________________________________________ 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: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
      • From: Craig Hopson <email@hidden>
References: 
 >AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning (From: John Zorko <email@hidden>)
 >Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning (From: Doug Wyatt <email@hidden>)

  • Prev by Date: Re: How to perform fast forward/rewind with AudioQueue
  • Next by Date: Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
  • Previous by thread: Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
  • Next by thread: Re: AudioQueueStop, AudioFileStreamParseBytes, kAudioQueueProperty_IsRunning
  • Index(es):
    • Date
    • Thread