Audiobus: Use your music apps together.

What is Audiobus?Audiobus is an award-winning music app for iPhone and iPad which lets you use your other music apps together. Chain effects on your favourite synth, run the output of apps or Audio Units into an app like GarageBand or Loopy, or select a different audio interface output for each app. Route MIDI between apps — drive a synth from a MIDI sequencer, or add an arpeggiator to your MIDI keyboard — or sync with your external MIDI gear. And control your entire setup from a MIDI controller.

Download on the App Store

Audiobus is the app that makes the rest of your setup better.

Question to any dev [SOLVED]

edited June 2023 in App Development

I have question to any dev who will be able to figure what fuckery is going on..

My problem: AVAudioUnitManager.getComponents() returns on my iPhone just 2 apple default instruments even through i have installed LOT of AUv3 instruments (which are normally visible in all hosts)

I am like WTF. End with ideas what's going on. Here screenhost, made very simple test showcase to avoid all possible bugs .. it's run on my device (not in simulator). Definitely 100% lot of other plugins there. But not listed, just apple stuff.

Comments

  • Just a guess, but in description you've got componentSubType: 0, and componentManufacturer: 0. Then you're matching against that in AVAudioUnitComponentManager.shared().(matching: description)

    You won't get any matches against that as those are both four character codes, will you? Or is 0 a wildcard of some sort?

  • edited June 2023

    I think the gotcha is kAudioUnitType_MusicDevice, which I think specifies the built-in music devices (iOS MIDI synth and the sampler).

    Try using kAudioUnitType_RemoteInstrument, kAudioUnitType_RemoteGenerator, kAudioUnitType_RemoteEffect, and you're likely to find more things showing up.

    The "remote" seems to be the way they're specifying audio units coming from somewhere other than iOS itself. (Wireless Audio receive is a RemoteGenerator, which not every Audio Unit host supports -- so it doesn't show up in some apps... But it has to be a generator for it to work as required... So if you're hosting an AUv3, please make sure to support RemoteGenerators!)

  • edited June 2023

    @wim said:
    Just a guess, but in description you've got componentSubType: 0, and componentManufacturer: 0. Then you're matching against that in AVAudioUnitComponentManager.shared().(matching: description)

    You won't get any matches against that as those are both four character codes, will you? Or is 0 a wildcard of some sort?

    0 is wildcard, means all

    @SecretBaseDesign said:
    I think the gotcha is kAudioUnitType_MusicDevice, which I think specifies the built-in music devices (iOS MIDI synth and the sampler).

    Try using kAudioUnitType_RemoteInstrument, kAudioUnitType_RemoteGenerator,

    nope, they return nothing, not even apple 2 default instruments .. based on all documentation MusicDevice is the right one..

    edit: tried most of kAudioUnitType_* - they all return either nothing OR apple default plugins ...

  • edited June 2023

    Yeah, I already had a look at Dendy's code, and I'm not seeing anything strange here.
    kAudioUnitType_MusicDevice is certainly the right type to look for when you want a list of instruments, and 0 should work perfectly as a wildcard.

    I'm using virtually the same bit of code in my hosting apps, although I use Objective-C and I'm not 100% sure whether that can make a difference or not.

  • I had the same issue, but weirdly only on my devices and not the simulator. Adding the Inter-App Audio capability to my host app fixed it.

  • @cp3 said:
    I had the same issue, but weirdly only on my devices and not the simulator. Adding the Inter-App Audio capability to my host app fixed it.

    Jeeez APPLE (huge facepalm)

    Adding "Inter-App Audio capability" solved the problem ..

    How obvious.. to be able to see installed AUv3 plugins, you need to enable IAA support .. it's so obvious that Apple even didn't mentioned it in docu lol

    THANKS !

  • Apple is simply unbelievable.

    When they remove IAA support, it may well be that AUv3 will also not work anymore 😅

  • cp3cp3
    edited June 2023

    @dendy said:

    @cp3 said:
    I had the same issue, but weirdly only on my devices and not the simulator. Adding the Inter-App Audio capability to my host app fixed it.

    Jeeez APPLE (huge facepalm)

    Adding "Inter-App Audio capability" solved the problem ..

    How obvious.. to be able to see installed AUv3 plugins, you need to enable IAA support .. it's so obvious that Apple even didn't mentioned it in docu lol

    THANKS !

    yeah, seems more like a bug on Apple's side than intended (yet undocumented) behaviour. I might file a radar.

  • edited June 2023

    plot twist - Apple is using IAA for communication between plugin and host :-D :-D :-D

    @tja said:
    Apple is simply unbelievable.

    When they remove IAA support, it may well be that AUv3 will also not work anymore 😅

    Lol that would be absolutely epic :-D :-D :-D

  • I was also bitten by this a few weeks ago. Took me three hours of back and forth, scratching my head, and finally found something on the Apple developer forums (IIRC).

    It kind of makes sense after you learn that on iOS the Audio Units run in a separate process and talk to the host with IPC, but it would spoil the fun if Apple mentioned in the hosting tutorial that you need to add the IAA entitlement…

  • @coniferprod said:
    I was also bitten by this a few weeks ago. Took me three hours of back and forth, scratching my head, and finally found something on the Apple developer forums (IIRC).

    It kind of makes sense after you learn that on iOS the Audio Units run in a separate process and talk to the host with IPC, but it would spoil the fun if Apple mentioned in the hosting tutorial that you need to add the IAA entitlement…

    Apple API documentation .. one simply must love it :trollface:

  • @dendy said:

    @coniferprod said:
    I was also bitten by this a few weeks ago. Took me three hours of back and forth, scratching my head, and finally found something on the Apple developer forums (IIRC).

    It kind of makes sense after you learn that on iOS the Audio Units run in a separate process and talk to the host with IPC, but it would spoil the fun if Apple mentioned in the hosting tutorial that you need to add the IAA entitlement…

    Apple API documentation .. one simply must love it :trollface:

    There's documentation? Where?

    Most of it is like this:

    which is the smug way of saying "you figure it out yourself Sherlock"

  • It’s quite obtuse. I was specifically referring to this: https://developer.apple.com/documentation/audiotoolbox/audio_unit_v3_plug-ins/incorporating_audio_effects_and_instruments

    I’ve been waiting and hoping (but not praying) that they make something like that for AUv3 instruments (there is one for effects).

  • edited June 2023

    @brambos said:

    @dendy said:

    @coniferprod said:
    I was also bitten by this a few weeks ago. Took me three hours of back and forth, scratching my head, and finally found something on the Apple developer forums (IIRC).

    It kind of makes sense after you learn that on iOS the Audio Units run in a separate process and talk to the host with IPC, but it would spoil the fun if Apple mentioned in the hosting tutorial that you need to add the IAA entitlement…

    Apple API documentation .. one simply must love it :trollface:

    There's documentation? Where?

    Most of it is like this:

    which is the smug way of saying "you figure it out yourself Sherlock"

    Thanks for confirming it's not just me unable to read (find) docs properly, was really doubting myself, after 25 years of coding experience with implementing all kinds of APIs i again feel like i just ended school and i'm completely dumb 😂 At least i feel like young again , with empty head ready to discover new knowledge again 😂

  • edited June 2023

    But the documentation used to be really good. Wind the clock back to 2008 when I started developing on the mac (didn't touch iOS until around 2010) and the documentation looked like this:

    https://developer.apple.com/library/archive/documentation/MusicAudio/Conceptual/AudioUnitProgrammingGuide/AudioUnitDevelopmentFundamentals/AudioUnitDevelopmentFundamentals.html

    The old documentation predates AUv3 but is still reasonably relevant for lower level audio stuff; unfortunately most, if not all, of the sample code is gone.

  • wimwim
    edited June 2023

    If you ask me it all started going to shit as "self documenting" code concepts took hold - the idea that you place a comment block at the start of a method or object and that gets turned into "documentation".

    Good idea, but who wants to scroll through in-code comments verbose enough to do more than summarize the purpose and parameters, let alone fully develop them when you're writing code. Then, the bean counters decide technical writers are redundant when it's all embedded in the code.

    It's not just Apple guilty of this, though they have taken it to extremes at least with the AUv3 related libraries.

Sign In or Register to comment.