VST3: synchronize AC when plugin's internal state changes
e.g. loading a u-he zebra preset using the plugin's GUI internally changes the controller state without using the `performEdit` API, but instead calls `restartComponent` wit the `kParamValuesChanged` flag to perform a a batch update. This now also updates Ardour's AutomationControl to match.
This commit is contained in:
parent
83d6b87249
commit
21d86b264a
@ -173,7 +173,9 @@ public:
|
||||
EndGesture,
|
||||
ValueChange,
|
||||
InternalChange,
|
||||
PresetChange };
|
||||
PresetChange,
|
||||
ParamValueChanged
|
||||
};
|
||||
|
||||
PBD::Signal3<void, ParameterChange, uint32_t, float> OnParameterChange;
|
||||
|
||||
|
@ -124,6 +124,8 @@ VST3Plugin::parameter_change_handler (VST3PI::ParameterChange t, uint32_t param,
|
||||
break;
|
||||
case VST3PI::ValueChange:
|
||||
_parameter_queue.write_one (PV (param, value));
|
||||
/* fallthrough */
|
||||
case VST3PI::ParamValueChanged:
|
||||
/* emit ParameterChangedExternally, mark preset dirty */
|
||||
Plugin::parameter_changed_externally (param, value);
|
||||
break;
|
||||
@ -1943,6 +1945,7 @@ VST3PI::update_shadow_data ()
|
||||
_input_param_changes.addParameterData (i->second, index)->addPoint (0, v, index);
|
||||
#endif
|
||||
_shadow_data[i->first] = v;
|
||||
OnParameterChange (ParamValueChanged, i->first, v); /* EMIT SIGNAL */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user