mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-07 20:10:13 +02:00
Use the new approach for creating plugin factory
Directly serializing and deserializing into objects was and more boilerplate heavy (since we now need two implementations even though we only use one), and also much less flexible because we can't wrap payloads in structs or provide optional values that way.
This commit is contained in:
+14
-15
@@ -45,18 +45,18 @@ void Vst3Logger::log_request(bool is_host_vst,
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_request(bool is_host_vst,
|
||||
const YaPluginFactory::Construct&) {
|
||||
log_request_base(is_host_vst,
|
||||
[](auto& message) { message << "GetPluginFactory()"; });
|
||||
}
|
||||
|
||||
void Vst3Logger::log_request(bool is_host_vst, const WantsConfiguration&) {
|
||||
log_request_base(is_host_vst, [](auto& message) {
|
||||
message << "Requesting <Configuration>";
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_request(bool is_host_vst, const WantsPluginFactory&) {
|
||||
log_request_base(is_host_vst, [](auto& message) {
|
||||
message << "Requesting <IPluginFactory*>";
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst, const Ack&) {
|
||||
log_response_base(is_host_vst, [&](auto& message) { message << "ACK"; });
|
||||
}
|
||||
@@ -76,16 +76,15 @@ void Vst3Logger::log_response(
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst,
|
||||
const YaPluginFactory::ConstructArgs& args) {
|
||||
log_response_base(is_host_vst, [&](auto& message) {
|
||||
message << "<IPluginFactory*> with " << args.num_classes
|
||||
<< " registered classes";
|
||||
});
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst, const Configuration&) {
|
||||
log_response_base(is_host_vst,
|
||||
[](auto& message) { message << "<Configuration"; });
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst,
|
||||
const YaPluginFactory& factory) {
|
||||
log_response_base(is_host_vst, [&](auto& message) {
|
||||
message << "<IPluginFactory*> with "
|
||||
<< const_cast<YaPluginFactory&>(factory).countClasses()
|
||||
<< " registered classes";
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user