Re: AU2 - Reset
Re: AU2 - Reset
- Subject: Re: AU2 - Reset
- From: Bill Stewart <email@hidden>
- Date: Wed, 25 Sep 2002 18:29:18 -0700
I'd agree with Chris' comments - there are no definable areas where AUReset
is required to be called, primarily I think because much the use of this API
is context dependent. Chris iterates a reasonable set of circumstances where
the API maybe called by a host... For instance, turning any sounding notes
off on a soft-synth can be achieved by calling AUReset...
However, there is one thing that can be made clearer.
If you're configuration has a lot to do with a particular format, then it is
I think entirely reasonable that changing a format after being initialized
is an invalid operation and an appropriate error can be returned...
The general practise for AudioUnit handling by a host is:
Open the AU
Configure it
Initialize it
- once initialized the AU is expected to be in a state that it is ready to
render, so the idea of doing further configuration after that state has been
set is NOT a recommended practise.
Thus, if you want to do configuration, the AU should be uninitialized,
configured, then reinitialized.
Bypassing an effect has many similarities.
If you're processing, then you're effect is bypassed, then it is turned on
again, you don't want to hear the delay tail from audio data that is now
stale...
(We should make this change in the SDK code, so that if bypass is set, then
the AU will automatically reset itself)...
Bill
on 25/9/02 12:25 PM, Chris Rogers wrote:
>
Marc,
>
>
In some ways, it is up to the client hosting the Audio Unit to decide when
>
it's appropriate to call AudioUnitReset(). The Audio Unit is assumed
>
to be in the "reset" state immediately after a call to AudioUnitInitialize(),
>
so your initialization code should make sure that happens. An Audio Unit
>
should be ready to start processing immediately after this call. You bring up
>
a good point about bypass. Audio Units should reset their state when
>
entering the bypass state and this is what happens in the SDK in the
>
AUEffectBase class. It seems like in most cases it would be wise to
>
reset the internal state after a stream format change, although I'd have
>
to look in the SDK code to see how this is handled.
>
>
From the host's point of view, it is probably a good idea to call
>
AudioUnitReset() on all Audio Units whenever the transport stops and
>
restarts, and certainly when the playback time changes on the timeline...
>
>
Chris Rogers
>
Core Audio
>
Apple Computer
>
>
>
>
> During what situations can an Audio Unit depend on receiving a call to
>
> Reset? After a stream format change? After processing stops, right
>
> before it restarts, or both? When entering bypass? When exiting bypass?
>
> Immediately after Initialize, or is the plugin expected to be ready to
>
> process immediately after Initialize?
>
>
>
> Thanks,
>
> Marc
>
_______________________________________________
>
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.
--
mailto:email@hidden
tel: +1 408 974 4056
__________________________________________________________________________
"Much human ingenuity has gone into finding the ultimate Before.
The current state of knowledge can be summarized thus:
In the beginning, there was nothing, which exploded" - Terry Pratchett
__________________________________________________________________________
_______________________________________________
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.