I have a VST/AU I’m developing, and if I have the plugin assigned to a track in ableton, I can close and reopen the plugin window and the GUI reflects param state, I can change the params via the Ableton controls and the GUI reflects the param state, but when I load a project fresh and open the plugin, the params are definitely set in the processor, and in the ableton plugin parameters, but my GUI isn’t reflecting the parameter values, just sitting at their defaults.
Any idea why this could be happening?
I have my sliders set up like:
addAndMakeVisible(dripSlider);
dripAttachment.reset (new SliderAttachment (valueTreeState, "drip", dripSlider));
Just a sanity check: did you implement getStateInformation and setStateInformation?
And did you try to debug, if that is actually executed and restores the data correctly?
The restrictions on type names and property names in XML are annoying.
Best to never use free text there, although I also often use that.
The plugin name is handy if you are creating presets, so maybe it’s best to add the plugin name as property to the state.
Not very experienced but I hope i can help. I will assume that you have different AudioProcessor.cpp and AudioProcessorEditor.cpp files.
First what are you trying to assign to dripParameter? If you want to assign the value i guess you should go for:
dripParameter = *parameters.getRawParameterValue(“drip”);
or if dripParameter is a member of the Editor:
dripParameter = *audioProcessor.parameters.getRawParameterValue(“drip”);