Hi. A question on VST3 bus layout
Surge is a synth which has a side chain input - not a main input but a side chain input.
When I hand coded our VST3 that meant I used the following layout:
addAudioInput(STR16("SideChain In"), SpeakerArr::kStereo, kAux);
addAudioOutput(STR16("Stereo Out"), SpeakerArr::kStereo);
addAudioOutput(STR16("Scene A Out"), SpeakerArr::kStereo);
addAudioOutput(STR16("Scene B Out"), SpeakerArr::kStereo);
the kAux
really matters. For one thing, it tells Reaper to not route audio through the synth.
If I look at juce_VST3_Wrapper.cpp I see this
info.busType = (dir == Vst::kInput && index > 0 ? Vst::kAux : Vst::kMain);
which basically says "input 0 is main and input 1 and above is aux’. But I want my input 0 to be aux.
So how do I accomplish this in juce? I tried making my bus layout
BusesProperties()
.withOutput("Output", AudioChannelSet::stereo(), true)
.withInput( "Ignored Input", AudioChannelSet::disabled(), false)
.withInput("Sidechain", AudioChannelSet::stereo(), true)
.withOutput("Scene A", AudioChannelSet::stereo(), false)
.withOutput("Scene B", AudioChannelSet::stereo(), false))
but when I scan with the validator then I get (correctly)
Info: => Audio Buses: [2 In(s) => 3 Out(s)]
Info: In [0]: "Ignored Input" (Main-Default Active)
Info: In [1]: "Sidechain" (Aux-Default Active)
Info: Out[0]: "Output" (Main-Default Active)
Info: Out[1]: "Scene A" (Main-Default Active)
Info: Out[2]: "Scene B" (Main-Default Active)
but the working pattern I need is
Info: => Audio Buses: [1 In(s) => 3 Out(s)]
Info: In [0]: "SideChain In" (Aux-Default Active)
Info: Out[0]: "Stereo Out" (Main-Default Active)
Info: Out[1]: "Scene A Out" (Main-Default Active)
Info: Out[2]: "Scene B Out" (Main-Default Active)
to work properly in the various tools.
(Of course I could just patch the vst3 wrapper I guess but am trying as hard as possible to ship surge xt without patching juce and I’m sure there’s an answer to this).
Thanks