What is the correct way to add/remove Nodes to AVAudioEngine?
What is the correct way to add/remove Nodes to AVAudioEngine?
- Subject: What is the correct way to add/remove Nodes to AVAudioEngine?
- From: Dmitry Klochkov via Coreaudio-api <email@hidden>
- Date: Sat, 2 Nov 2019 21:49:59 +0300
I am implementing AUv3 support in my sequencer app. My app is a host and I
load only Instrument units for now. I am using AVAudioEngine. I want to
know what is the correct procedure to add and remove Instrument nodes from
AVAudioEngine.
Firstly I tried to attach nodes and connect them to the MainMixer while the
AVAudioEngine is running, but it didn't work (the execution was hanging on
the audioEngine.connect method).
So now, before doing any manipulations on the AVAudioEngine, I stop it with
the stop method. All works fine except the case when there are some audio
playing. In that case the stop method hangs and after about 15 seconds the
following error is printed:
*[mcmx] 313: *** AUMultiChannelMixer::Cleanup() -- ERROR, attempting to
cleanup while rendering*
Before I stop the AVAudioEngine I stop all the midi notes on the connected
Instrument unit. But there still could be some audio playing for a while
(reverbs, delays etc).
So I guess, before stoping the AVAudioEngine I should ensure that all audio
is stopped.
Is there a way to safely stop all audio on an audio unit?
Best wishes,
Dmitry Klochkov
_______________________________________________
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