mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-14 12:30:00 +02:00
Implement IEditController::getParamNormalized()
This commit is contained in:
@@ -355,6 +355,16 @@ void Vst3Logger::log_request(
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_request(
|
||||
bool is_host_vst,
|
||||
const YaEditController2::GetParamNormalized& request) {
|
||||
log_request_base(is_host_vst, [&](auto& message) {
|
||||
message << request.instance_id
|
||||
<< ": IEditController::getParamNormalized(id = " << request.id
|
||||
<< ")";
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_request(bool is_host_vst,
|
||||
const YaPluginBase::Initialize& request) {
|
||||
log_request_base(is_host_vst, [&](auto& message) {
|
||||
|
||||
@@ -94,6 +94,8 @@ class Vst3Logger {
|
||||
const YaEditController2::NormalizedParamToPlain&);
|
||||
void log_request(bool is_host_vst,
|
||||
const YaEditController2::PlainParamToNormalized&);
|
||||
void log_request(bool is_host_vst,
|
||||
const YaEditController2::GetParamNormalized&);
|
||||
void log_request(bool is_host_vst, const YaPluginBase::Initialize&);
|
||||
void log_request(bool is_host_vst, const YaPluginBase::Terminate&);
|
||||
void log_request(bool is_host_vst, const YaPluginFactory::Construct&);
|
||||
|
||||
@@ -83,6 +83,7 @@ using ControlRequest = std::variant<Vst3PluginProxy::Construct,
|
||||
YaEditController2::GetParamValueByString,
|
||||
YaEditController2::NormalizedParamToPlain,
|
||||
YaEditController2::PlainParamToNormalized,
|
||||
YaEditController2::GetParamNormalized,
|
||||
YaPluginBase::Initialize,
|
||||
YaPluginBase::Terminate,
|
||||
YaPluginFactory::Construct,
|
||||
|
||||
@@ -300,8 +300,48 @@ class YaEditController2 : public Steinberg::Vst::IEditController,
|
||||
virtual Steinberg::Vst::ParamValue PLUGIN_API
|
||||
plainParamToNormalized(Steinberg::Vst::ParamID id,
|
||||
Steinberg::Vst::ParamValue plainValue) override = 0;
|
||||
|
||||
/**
|
||||
* Message to pass through a call to
|
||||
* `IEditController::getParamNormalized(id)` to the Wine plugin host.
|
||||
*/
|
||||
struct GetParamNormalized {
|
||||
using Response = PrimitiveWrapper<Steinberg::Vst::ParamValue>;
|
||||
|
||||
native_size_t instance_id;
|
||||
|
||||
Steinberg::Vst::ParamID id;
|
||||
|
||||
template <typename S>
|
||||
void serialize(S& s) {
|
||||
s.value8b(instance_id);
|
||||
s.value4b(id);
|
||||
}
|
||||
};
|
||||
|
||||
virtual Steinberg::Vst::ParamValue PLUGIN_API
|
||||
getParamNormalized(Steinberg::Vst::ParamID id) override = 0;
|
||||
|
||||
/**
|
||||
* Message to pass through a call to
|
||||
* `IEditController::setParamNormalized(id, value)` to the Wine plugin host.
|
||||
*/
|
||||
struct SetParamNormalized {
|
||||
using Response = UniversalTResult;
|
||||
|
||||
native_size_t instance_id;
|
||||
|
||||
Steinberg::Vst::ParamID id;
|
||||
Steinberg::Vst::ParamValue value;
|
||||
|
||||
template <typename S>
|
||||
void serialize(S& s) {
|
||||
s.value8b(instance_id);
|
||||
s.value4b(id);
|
||||
s.value8b(value);
|
||||
}
|
||||
};
|
||||
|
||||
virtual tresult PLUGIN_API
|
||||
setParamNormalized(Steinberg::Vst::ParamID id,
|
||||
Steinberg::Vst::ParamValue value) override = 0;
|
||||
|
||||
Reference in New Issue
Block a user