Problems with multibus in Pro Tools

Hi

I am having some unexpected behaviour with multibus in Pro Tools. I am trying to set up a plugin that has an aux output that exists when the plug-in is in a 5.1 and 7.1 mode, but not in mono, stereo or quad.

I have set up a simple test audio processor bus as follows:

Proj44srTestAudioProcessor::Proj44srTestAudioProcessor()
     : AudioProcessor (BusesProperties()
                       .withInput  ("Input Main",  AudioChannelSet::stereo(), true)
                       .withOutput ("Output Main", AudioChannelSet::stereo(), true)
                       .withOutput ("Output Aux", AudioChannelSet::stereo(), true)
                       )
{
}

I am setting channel behaviour in isBusesLayoutSupported. I provide two examples:

Initially I tested to be sure I am setting the plug-in up correctly to provide an aux as below.

bool Proj44srTestAudioProcessor::isBusesLayoutSupported (const BusesLayout& layouts) const
{
    // disallow layout where in/out count is not equal
    if(layouts.getMainOutputChannelSet() != layouts.getMainInputChannelSet()) return false;
    
    // check we have the expected number of output busses (main + aux)
    if(layouts.outputBuses.size() != 2) return false;

    // get the current aux channel set
    AudioChannelSet aux_channel_set = layouts.getChannelSet(false, 1);
    
    // allow mono + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::mono() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow stereo + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::stereo() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow quad + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::quadraphonic() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow 5.1 + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::create5point1() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow 7.1 + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::create7point1() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow nothing else
    return false;
}

All busses work as expected, they can be used on a track of widths mono-5.1, and an “Output Aux” stereo source can be selected for input to a Pro Tools ‘Aux Input’ stereo track.

This is great, so I attempt to disable the aux channel when the plug-in is operating in channel modes that I do not require it.

bool Proj44srTestAudioProcessor::isBusesLayoutSupported (const BusesLayout& layouts) const
{
    // disallow layout where in/out count is not equal
    if(layouts.getMainOutputChannelSet() != layouts.getMainInputChannelSet()) return false;
    
    // check we have the expected number of output busses (main + aux)
    if(layouts.outputBuses.size() != 2) return false;

    // get the current aux channel set
    AudioChannelSet aux_channel_set = layouts.getChannelSet(false, 1);
    
    // allow mono + disabled aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::mono() && aux_channel_set == AudioChannelSet::disabled()) return true;

    // allow stereo + disabled aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::stereo() && aux_channel_set == AudioChannelSet::disabled()) return true;

    // allow quad + disabled aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::quadraphonic() && aux_channel_set == AudioChannelSet::disabled()) return true;

    // allow 5.1 + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::create5point1() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow 7.1 + stereo aux layout
    if(layouts.getMainOutputChannelSet() == AudioChannelSet::create7point1() && aux_channel_set == AudioChannelSet::stereo()) return true;

    // allow nothing else
    return false;
}

Some unexpected problems:

  1. Plugin cannot be inserted on Mono and Quad Pro Tools tracks at all (as though they were not defined at all)
  2. Stereo plugin includes the stereo aux, but the aux should be disabled
  3. Others work as expected (they can be added to a track of proper track count, and an aux stereo channel can be selected for input with a Pro Tools ‘Aux Input’ stereo track)

The reason I am doing this quite strange thing is that Pro Tools does not really facilitate channel counts above 7.1.2 (or any concept of height at all in a 5.1). Normally for atmos that’s fine, all height is intended to be thrown to a stereo height channel and leave the detail to objects. However for music it can be quite desirable to use a 7.1.2 atmos bed and provide a couple of extra outs for use with atmos objects as additional reverberant output to help decorrelate what’s at height, improve localisation etc; it makes sense to provide these as a couple of additional aux outputs if there are sufficient atmos objects free in the session to do it. It is not really necessary to provide those for the stereo, quad, modes though so if they can be disabled it makes what amounts to a bit of a messy hack slightly tidier for non-atmos users.

I’m using the latest Pro Tools. Any ideas what I am doing wrong?

Thanks
Matt