Plugin load is extremely slow

#1

Hello. I’m writing a simple VST host using this code:

OwnedArray<PluginDescription> pluginDescriptions;
    KnownPluginList pluginList;
    AudioPluginFormatManager pluginFormatManager;
    
    pluginFormatManager.addDefaultFormats();
    
    for (int i = pluginFormatManager.getNumFormats(); --i >= 0;)
    {
        pluginList.scanAndAddFile (String (path),
                                   true,
                                   pluginDescriptions,
                                   *pluginFormatManager.getFormat(i));
    }

It worked well since recently it becomes very very slow (about 1min). When I tried to debug it, I saw that it get stuck in this line:
**auto** err = AudioComponentInstanceNew(auComponent, &amp;audioUnit);
in the class **void** AudioUnitPluginFormat::findAllTypesForFile
in Juce_AudioUnitPluginFormat.mm

Any idea?

0 Likes

#2

Can you see which AU it’s trying to load when it slows down? It could be that you’ve installed an AudioUnit recently which takes a while to load.

0 Likes