Hi, after my VST plugin is updated to JUCE 4 (VST SDK is also updated), when opening projects saved from previous versions, all parameters are lost. I debug it and find setStateInformation() is not called at all. Does anyone have a clue? Save & Load with same version works fine.
Tested on Cubase and Studio One, both failed.
Clearly the hosts don’t think it’s the same plugin. Maybe a name or ID or version descriptor has changed.
Yes. But the weird thing is that when the older version loads a project saved from newer version, all parameters are there.
Problems with setStateInformation not being called
You probably need to set JUCE_VST_RETURN_HEX_VERSION_NUMBER_DIRECTLY=1 in the user part of your AppConfig.h. Without that, the newer JUCE will produce a version number of, e.g., 0.1.2.0 instead of 220.127.116.11 for Cubase and some other hosts, which will make Cubase think that version 18.104.22.168 is newer than version 22.214.171.124 (and therefore it won’t load the settings saved with the “older” version).
Yes! It works!