RE: Driver seems a little dizzy while running more than on mediaplayer
RE: Driver seems a little dizzy while running more than on mediaplayer
- Subject: RE: Driver seems a little dizzy while running more than on mediaplayer
- From: "David Tan" <email@hidden>
- Date: Wed, 25 Feb 2009 12:52:30 -0800
Hi Jeff,
Thanks for your reply!
Yes, the noise only occurs in multi-client-case.
So you mean: every user-space client has its own thread to call
IOAudioEngine::clipOutputSamples(), right?
And every time of clipOutputSamples() being called, all audio data in mixBuf
are for just one client, right?
If I got misunderstanding of your comments, please correct me.
Actually I have an interim buffer to maintain the audio data from user-space
client, and a write and a read pointer respectively to it. While
clipOutputSamples() is being called, I move the audio data in mixBuf into
this interim buffer and update the write pointer. At the same time, a DCL
program will read data in this interim buffer and transmit them to my
Firewire device. Of course, I'll update the read pointer of it during this
operation.
Regarding the timing issue you said, I wonder if there's structure problem
of my current solution. Usually, how should we handle the timing in case of
multi-client?
Thanks a lot!
Sincerely yours,
David Tan
Software Engineer
Dextrys Co., Ltd.
-----Original Message-----
From: coreaudio-api-bounces+david.tan=email@hidden
[mailto:coreaudio-api-bounces+david.tan=email@hidden] On
Behalf Of Jeff Moore
Sent: 2009年2月23日 9:39
To: Apple CoreAudio-API
Subject: Re: Driver seems a little dizzy while running more than on
mediaplayer
If your driver is only making noise when there are multiple clients,
it probably means that your driver has a problem with threading. It
sounds like the multiple real time threads in the client processes is
perturbing your driver timing enough to cause it to drop bad time
stamps.
On Feb 23, 2009, at 3:57 AM, David Tan wrote:
> I'm working on an kernel Firewire audio driver and found a
> troublesome issue.
> While I’m using more than one player (e.g. iTunes and HALLab) to
> play music, sometime there’ll be noise. And then I have to stop both
> of them and start playing again, the noise will disappear.
> My question is: what’s CoreAudio do in this case? Anything I should
> pay special attention to in my driver to eliminate the noise?
--
Jeff Moore
Core Audio
Apple
_______________________________________________
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