Given that many AVFoundation audio components are built on AudioUnits it occurred to me that it might be "nice" to leverage some of these components as part of an AUv3 implementation and let those guys do some of the heavy lifting, i.e. populating buffers and so on.
A good example is perhaps (my obsession) AVAudioUnitSampler, all the more tempting given that the internalRenderBlock for the underlying AUAudioUnit was recently exposed not so long ago (iOS 11 maybe?)
Two literal questions really I guess...
1) Is trying to use AVFoundation "stuff" as part of an AUv3 implementation like this a "bad idea" ?
2) Alternatively, if this could work "in theory", the thing that's totally unclear to me is how to properly integrate AVAudioEngine given that (please correct me if I'm wrong) AVAudioUnitSampler totally needs AVAudioEngine to be up and running to do its thing. During some hack tests, I was able to get an AV sampler-based AU instantiated and making noise but couldn't seem to route outputs correctly to the host. There were also errors around setting maximumFramesToRender that made me suspect the answer to question 1 is "yes".
And finally, mostly likely a rhetorical question...
3) Is it just me, or does the audio side of AVFoundation, and the current "push" towards AUv3 seem at odds?
A good example is perhaps (my obsession) AVAudioUnitSampler, all the more tempting given that the internalRenderBlock for the underlying AUAudioUnit was recently exposed not so long ago (iOS 11 maybe?)
Two literal questions really I guess...
1) Is trying to use AVFoundation "stuff" as part of an AUv3 implementation like this a "bad idea" ?
2) Alternatively, if this could work "in theory", the thing that's totally unclear to me is how to properly integrate AVAudioEngine given that (please correct me if I'm wrong) AVAudioUnitSampler totally needs AVAudioEngine to be up and running to do its thing. During some hack tests, I was able to get an AV sampler-based AU instantiated and making noise but couldn't seem to route outputs correctly to the host. There were also errors around setting maximumFramesToRender that made me suspect the answer to question 1 is "yes".
And finally, mostly likely a rhetorical question...
3) Is it just me, or does the audio side of AVFoundation, and the current "push" towards AUv3 seem at odds?