Hi. I have a VST FX plugin that has the typical stereo in/out buses. I’m trying to modify this so that it also has stereo send and return buses. The application: I have a full DSP guitar amp model with a preamp and power amp and I want to use an EQ VST to modify the EQ between the preamp and power amp of the model.
[Background info: JUCE v8.0.3, MacOS 14.0, Apple Silicon M2, if it matters]
I’ve tried the plugin in Presonus Studio One as well as the Element VST host. I believe that Studio One does not allow the full stereo in/out/send/return bus config (return input bus always shows up as disabled). With Element, I seem to be getting all of the buses showing up as enabled in my processBlock() function. Thus, I’m testing with Element.
However, even though all four buses are showing up as AudioChannelSet::stereo (in Element), I’m still not getting the correct audio into the plugin. I’m testing with a simple tone generator VST in front of my plugin and the level meters in the plugin are inactive (tone generator is working, as I have a scope VST to view the waveform).
I am not enforcing the send/return to be active in isBusesLayoutSupported(), as it is OK for there to be no send/return connections. My desire is that if send and return are not routed to anything, then inside my plugin, the send buffer just gets copied to the return buffer (just like a send/return FX loop in an amplifier–the send and return are normalled together if no plug is inserted into the jack).
Here’s the top part of my AudioProcessor ctor:
MyAudioProcessor::MyAudioProcessor()
: juce::AudioProcessor (BusesProperties()
.withInput ("Input", AudioChannelSet::stereo(), true)
.withInput ("FXReturn", AudioChannelSet::stereo(), true)
.withOutput ("Output", AudioChannelSet::stereo(), true)
.withOutput ("FXSend", AudioChannelSet::stereo(), true)
) ...
My isBusesLayoutSupported() implementation:
bool MyAudioProcessor::isBusesLayoutSupported (const BusesLayout& layouts) const
{
if (layouts.getMainOutputChannelSet() == AudioChannelSet::stereo()) {
if ((layouts.getMainInputChannelSet() == AudioChannelSet::mono()) ||
layouts.getMainInputChannelSet() == AudioChannelSet::stereo()) {
return true;
}
}
return false;
}
Questions:
- Do I need to explicitly call addBus() to enable the send and return buses? It seems like they are showing up as enabled in Element, so I don’t think so, but wanted to verify.
- Can I rely on the default implementations of functions in the AudioProcessor base class like
applyBusLayouts()andaudioIOChanged(), etc., or do I need to override those?
Anything I might be missing here? All help is appreciated.
