Load a vst .dll into an AudioProcessor / AudioPluginInstance


#1

    StringArray stringArray;
    KnownPluginList plugList;
    AudioPluginFormatManager pluginFormatManager;
    OwnedArray< PluginDescription > typesFound;
    String pluginLoadError;
    AudioPluginInstance* test;


AudioProcessor* WrapIt::returnMassiveIntoAudioProcessor(){
    stringArray.add("C:\Program Files(x86)\Steinberg\VSTPlugins\Massive.dll");
    pluginFormatManager.addDefaultFormats();
    plugList.scanAndAddDragAndDroppedFiles(pluginFormatManager, stringArray, typesFound);
    jassert(plugList.getNumTypes() > 0); // It crash here !

    test = pluginFormatManager.createPluginInstance(*typesFound[0], 44100, 512, pluginLoadError);
    jassert(test != nullptr);
    return test;
}

Hello everybody,

I try to convert my massive vst .dll to an AudioProcessor.

I use a KnownPluginList object, but when i call the
scanAndAddDragAndDroppedFiles
("Massive.dll") method nothing is added to it.

Any suggestion please ? :)

Thanks a lot

Louis

 

 


#2

It's ok,

I use scanAndAddFile and it works pretty well now !