Multiple audio stream on iOS (multiRoute)

Hi JUCE team,

do you plan to implement to implement multiRoute for iOS?
https://developer.apple.com/documentation/avfoundation/avaudiosession/category/1616484-multiroute

Best,
Emanuele

No immediate plans for this, although from reading the docs it looks like we have a lot of the foundations for this in place already in the iOS audio code. Does it work if you make the following changes to juce_ios_Audio.cpp?

Add the multi-route category to the options in setAudioSessionCategory():

if (category == AVAudioSessionCategoryPlayAndRecord)
    options |= (AVAudioSessionCategoryOptionDefaultToSpeaker
              | AVAudioSessionCategoryOptionAllowBluetooth
              | AVAudioSessionCategoryOptionAllowBluetoothA2DP
              | AVAudioSessionCategoryMultiRoute);

Change handleRouteChange() to reconfigure the device on route change:

switch (reason)
{
case AVAudioSessionRouteChangeReasonCategoryChange:
case AVAudioSessionRouteChangeReasonOverride:
    break;
case AVAudioSessionRouteChangeReasonUnknown:
case AVAudioSessionRouteChangeReasonNewDeviceAvailable:
case AVAudioSessionRouteChangeReasonOldDeviceUnavailable:
case AVAudioSessionRouteChangeReasonWakeFromSleep:
case AVAudioSessionRouteChangeReasonNoSuitableRouteForCategory:
case AVAudioSessionRouteChangeReasonRouteConfigurationChange:
{
    hardwareInfoNeedsUpdating = true;
    triggerAsyncUpdate();
    break;
}
// No default so the code doesn't compile if this enum is extended.
}