Re: MTCoreAudioDevice: ioProc called a limited number of times and then halts
Re: MTCoreAudioDevice: ioProc called a limited number of times and then halts
- Subject: Re: MTCoreAudioDevice: ioProc called a limited number of times and then halts
- From: Michael Thornburgh <email@hidden>
- Date: Fri, 5 Mar 2004 12:53:56 -0800
i've never seen behavior like that before.
i can think of one reasonable explanation: your IO cycles are tied to
the object (currentDevice) on which you did the
setIOProc:withClient
data:/deviceStart, so if that object is
deallocated, its IO cycles will stop. objects obtained from the
MTCoreAudio class methods (like +allDevices) are autoreleased, so if
you don't retain the object, it will disappear when the autorelease
pool is deallocated, and its IO will likewise stop.
if that's not the issue, we should probably take this off-list (since
it's not a HAL problem) and post a summary for interested parties.
-mike
On Mar 5, 2004, at 12:21 PM, Zachary Drew wrote:
I wrote some code that captures audio from the line-in. I originally
wrote
it directly with HAL and I've been converting it to use the MTCoreAudio
wrapper version 1.2.0. When I converted it to use
setIOProc:withClientData and deviceStart, my ioProc only gets called a
few
times (20 times or so) and then it stops. When I change it back to
straight HAL my ioProc exhibits the expected behavior.
Here is what I use:
[currentDevice setIOProc:ioProc withClientData:self];
[currentDevice deviceStart];
I then use a NSLog call within my ioProc to see when it's called.
Has anyone seen something like this before?
Thanks,
-Zach
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.