Re: CoreAudio Level Of Death
Re: CoreAudio Level Of Death
- Subject: Re: CoreAudio Level Of Death
- From: Doug Wyatt <email@hidden>
- Date: Thu, 11 Nov 2004 08:52:42 -0800
On Nov 11, 2004, at 3:46, Urs Heckmann wrote:
Hiya,
Hi Urs,
it happens quite often to me that a filter or something I'm working on
gets instable and kicks out very high peaks. In those cases, I can
only hear a short *click* and the AU plugin gets muted.
The problem is, the plugin keeps being muted even if it clears all
buffers afterwards and delivers reasonable audio values. - I suspect,
this is a "feature" of CoreAudio.
My question:
What is the critical factor upon which CoreAudio mutes an Audio Unit?
Is it something like floats being NaNs or Infinity?
It would be cool to know, so I could add this check into my stuff.
No one is actually examining the buffers and deciding that your AU must
be muted (unless it's whatever AU host you're testing with ... not our
sample code).
NaNs are the antimatter of audio, however -- once you've put one out,
it turns every other floating point number it touches into a NaN. So if
there are any filters or regenerating delays in the signal path, one
NaN will silence the chain until that DSP code is reset (unless it's
smart enough to periodically check for NaNs). It could be that the
Apple built-in drivers have some filters, I don't know offhand and if
they do, it probably depends on the sound hardware and whether you're
using the internal speakers vs. line out.
You can check for NaNs with isnan() (just be aware that it can be
pretty expensive; you probably don't want this check in shipping code).
hth,
Doug
_______________________________________________
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