From c62c67a96cd66c3ef169774df112b390f68af556 Mon Sep 17 00:00:00 2001 From: Robbert van der Helm Date: Sun, 10 Jan 2021 23:34:23 +0100 Subject: [PATCH] Add a message structs for IAutomationState --- .../vst3/plugin/automation-state.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/common/serialization/vst3/plugin/automation-state.h b/src/common/serialization/vst3/plugin/automation-state.h index c19db200..9bb4bf3f 100644 --- a/src/common/serialization/vst3/plugin/automation-state.h +++ b/src/common/serialization/vst3/plugin/automation-state.h @@ -64,6 +64,24 @@ class YaAutomationState : public Steinberg::Vst::IAutomationState { inline bool supported() const { return arguments.supported; } + /** + * Message to pass through a call to + * `IAutomationState::setAutomationState(state)` to the Wine plugin host. + */ + struct SetAutomationState { + using Response = UniversalTResult; + + native_size_t instance_id; + + int32 state; + + template + void serialize(S& s) { + s.value8b(instance_id); + s.value4b(state); + } + }; + virtual tresult PLUGIN_API setAutomationState(int32 state) override = 0; protected: