Re: Stabilizing AudioQueue
Re: Stabilizing AudioQueue
- Subject: Re: Stabilizing AudioQueue
- From: William Stewart <email@hidden>
- Date: Fri, 12 Dec 2008 14:49:19 -0800
10.5.6 has a number of changes for audio queue and audio file stream,
and in this update we believe we've fixed many/most (even hopefully
all) of the issues with these APIs that developers have found since
Leopard.
Bill
On Dec 12, 2008, at 7:21 AM, Greg Wilson wrote:
On 14-Sep-08, at 0:38 PM, Nick Zitzmann wrote:
I'm trying to work with the AudioQueue class, but I keep running
into problems with it that I need help solving.
My application creates several Objective-C objects that have an
internal AudioQueue. The queue is fed a stream of linear PCM. I've
based my code on the AudioQueueTools example code, and in my
playback function, I use memcpy() to copy an internal buffer of PCM
into each AudioQueueBufferRef.
When the very first object with PCM is created, everything works
fine. It's starting with the second object that things start to
fall apart. First off, I've found that calling AudioQueueDispose()
with inImmediate set to true causes a buffer overrun that trips
Guard Malloc when the app next creates a new AudioQueue and calls
AudioQueueAllocateBuffer(). I have filed bug #6218335 on this matter.
So when the buffer is disposed with inImmediate set to false, the
buffer no longer overruns, but now when AudioQueueStart() is
called, it works for the first few AudioQueues that come and go,
but after a while no sound effects are played. When I examined the
thread that's supposed to render the audio, it appears to be
throwing a C++ exception of some sort in AUNetSendEntry(), which
might explain things, but AudioQueueStart() still returns noErr.
Has anyone ever tried allocating and deallocating more than one
AudioQueue in an application, and if so, have you ever had these
problems? I need multiplexing, so going to a single AudioQueue is
not an option.
Alternately, does anyone have any working alternative classes to
AudioQueue that I can use?
I've been having similar problems and wondered if you had resolved
this. I get GuardMalloc breaking when creating a second queue after
an AudioQueueDispose.
I've also been frustrated trying to set volume on a queue if I have
multiple queues running at the same time. Basically, if only one
queue is running I can set the volume and it works nicely. If two
queue are running I get some weirdness. Setting the volume on the
first queue created causes a volume change in the second queue.
Changing the volume on the second queue has no effect.
yes, this is a known issue and is fixed in the update
When I query the volume parameter, the setting has "taken", ie the
volume is what I set it at. However, the volume emitted from the
speakers has not changed.
I've also been trying to search the mailing lists for other
AudioQueue issues and information. I get zero results when doing a
search. When I search the mailing lists for "coreaudio", "audio" or
even "carbon" the most current hit I get is from May2007. Is the
list search broken?
_______________________________________________
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