I have a JUCE 4.3 Plugin VST2 which has no channel limitation, but uses a default channel configuration of stereo/stereo
No if i open this in a JUCE 4.0 hosts it, it will open with 8/8 channel configuration, but uses internally the 2/2 channel configuration.
I thought the default channel configuration, is a fallback, to open the plugin in older hosts, with the correct number of channels, but its seems it does not work. This must be fixed.
So in older hosts, the number of vstEffect.numInputChannels/numOutputChannels reports the number of current channels, i tried this, but still get crashes when insert this kind of plugin as a surround plugin, it seems that internal buffer are not big enough? Maybe someone with deeper wrapper knowledge (@fabian) knows what to do?
So, the problem is, the default channel number makes no sense, when older hosts open the plugin with the maximum number of channels (I thought this have been fixed), but the plugin thinks it has the default number of channels.
And thats how my plugin with the latest juce (develop) look like, with the old juce 4.0 host (there are lot of hosts the behave like that) with a default channel configuration stereo/stereo
That’s odd. If you have set the default layout in the AudioProcessor constructor then the host demo will use that. Try the GainPlugin demo in JUCE/examples/PluginSamples/GainPlugin. This will appear as a stereo-in/stereo-out plug-in by default.
I’m talking about older Plugin Hosts, which do not support multiple Configuration, like that one in JUCE_4_0
But the same goes for a lot for other hosts.
(Isn’t that the reason why we have the Default Channel-Configuration? )
The problem is, either the plugin be opened with the full number of channels AND report the full number of channels in the plugin internally (which can be limited with isBusesLayoutSupported)
OR
it should be opened with the default number of channels AND report the number of default channels internally to the plugin
But the current behavior is, it opens the number of maximum of channels (because thats what is reported to the host), and opens the plugin Internally with then default number of channels.
This breaks all old hosts, which do not support multiple channel configurations. The old behavior was more consistent.
So at least, the number which is used internally must be the same, which the hosts is seeing.
(I could live with that, even if its not the default number of channels)
The problem is that vstEffect.numInputChannels and vstEffect.numOutputChannelsneeds to be the maximum number of channels. So I don’t understand what you propose. If I make those numbers any smaller then there is no way to increase the channel number beyond the default.
the problem is, that older hosts which open the plugin with maximum of channels (like juce 4.0), do not realize that the plugin is only working with a smaller number of channels internally.
Not sure what we can do…
Maybe i just use the default number of channels = the maximum number channels for VST
(I hoped that this behavior had been fixed with the latest juce)
mhh, but than again, it wouldn’t support more than the number of default channels, in VST2 hosts that support multiple channel configurations (or better less than maximum) like Cubase (which was always working, even with older juce releases)