No plugin formats added on 4.2.2, so no plugin hosting


#1

Hi after I pulled 4.2.2 from Master, I got some issues with plugin hosting
Just tested on Windows, and the AudioPluginFormatManager::addDefaultFormats() does not add any formats even if they are enabled in the Projucer, (Downloaded fresh PJ, Checked settings and re-saved project)

There seems to be added some defines in there

void AudioPluginFormatManager::addDefaultFormats()
{
   #if JUCE_DEBUG
    // you should only call this method once!
    for (int i = formats.size(); --i >= 0;)
    {
       #if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)
        jassert (dynamic_cast<VSTPluginFormat*> (formats[i]) == nullptr);
       #endif

       #if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)
        jassert (dynamic_cast<VST3PluginFormat*> (formats[i]) == nullptr);
       #endif

       #if JUCE_PLUGINHOST_AU && (JUCE_MAC || JUCE_IOS)
        jassert (dynamic_cast<AudioUnitPluginFormat*> (formats[i]) == nullptr);
       #endif

       #if JUCE_PLUGINHOST_LADSPA && JUCE_LINUX
        jassert (dynamic_cast<LADSPAPluginFormat*> (formats[i]) == nullptr);
       #endif
    }
   #endif

   #if JUCE_PLUGINHOST_AU && (JUCE_MAC || JUCE_IOS)
    formats.add (new AudioUnitPluginFormat());
   #endif

   #if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)
    formats.add (new VSTPluginFormat());
   #endif

   #if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)
    formats.add (new VST3PluginFormat());
   #endif

   #if JUCE_PLUGINHOST_LADSPA && JUCE_LINUX
    formats.add (new LADSPAPluginFormat());
   #endif
}

On windows under debug builds this adds 0 formats on my system…


#2

I think it might have to do with using “JUCE_WIN” and not “JUCE_WINDOWS” ?
In that case it is a problem in these files:

juce_AudioPluginFormatManager.cpp
juce_VST3PluginFormat.h
juce_VST3PluginFormat.cpp
juce_VSTPluginFormat.cpp
juce_VSTPluginFormat.h


#4

Should be fixed now, please update to the newest tip.


#5

Works! thank you for the quick fix :grinning: