Re: AudioDeviceStop and ioProc
Re: AudioDeviceStop and ioProc
- Subject: Re: AudioDeviceStop and ioProc
- From: Steve Checkoway <email@hidden>
- Date: Fri, 12 May 2006 17:21:57 -0700
On May 12, 2006, at 11:40 AM, Jeff Moore wrote:
On May 11, 2006, at 6:18 PM, Tim Dorcey wrote:
Let me say this clearly so that there is no misconception: The only
way to get guaranteed behavior from AudioDeviceStop() is to call it
on the IO thread. The guarantee that is given is twofold. First, the
IOProc being stopped will never get called until Start() is called
again. Second, any output data supplied in that final call to the
IOProc will get sent to the hardware.
As a followup to this, does the same hold true for AudioHardwareUnload
() or will this not return until the HAL is in its
"essentially...uninitialized state"?
So, it sounds like the best way to terminate audio capture is to
just have
my ioProc call AudioDeviceStop for itself. Easy enough. For some
reason, I
was under the impression that it would not be safe to call
AudioDeviceStop
from within the ioProc.
This is indeed the best way to stop. In fact, this is exactly how
AUHAL deals with stopping.
How about removing property listeners? Can the property listener
still be called after AudioDeviceRemovePropertyListener() has
returned? If so, what is the recommended way of handling that?
Thanks,
- Steve
_______________________________________________
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