AAX plugin recalling slider positions after save/re-open project even though getStateInformation/setStateInformation is empty

Hi all, first post so here goes.

I am having problem with the demo version of our plugin (only the AAX in ProTools, other versions seem to work correctly) recalling the slider positions after closing the project and re-opening.

both getStateInformation & setStateInformation are empty (only in demo version).

I tried removing the AudioProcessorValueTreeState::SliderAttachment on each slider in the demo version only, and this worked (sort of) but now the sliders are re-setting back to default position every time the plugin window is closed and re-opened, in the same DAW session.

using JUCE v7.0.5

p.s. I haven’t seen this behaviour before in previous testing with ProTools (i don’t think so, would have noticed it i am sure?), but have updated my version since testing last plugin.

Thanks :slight_smile:

I believe this is happening because Pro Tools saves and restores the value of all automated parameters exposed by your plug-in, separately and in addition to the data that you manage with get/setStateInformation().
So, even when you are not implementing those virtual functions, still Pro Tools saves the parameter values in its session data and restores them when you recall it.

That being said, perhaps you can have some luck by using the macro JucePlugin_AAXDisableSaveRestore provided by JUCE. I don’t have experience with it, but maybe it does exactly what you want.

2 Likes

Thankyou :slight_smile:

Will give it a look/try.

If not, will probably just have to move to a time based demo with periodic white noise or something.

So decided instead to keep it so AudioProcessorValueTreeState::SliderAttachment as not defined in Demo build, but then grab the values from the Processor and use those values in the Editor’s constructor for the Slider.setValue().

That was my initial thought as to how to handle it but i thought it was a little “sloppy”, but it is now working the way i want, and also shuts down the possibility of people using automation as a way to recall settings in the Demo plugin (which has no time limit).

Hopefully doing it this way won’t cause other unexpected issues. Will keep testing.