Allow indirect IConnectionPoint connections

This is needed to support Ardour. These extra hops and serialization
steps will probably hurt performance, but outside of some huge hacks (to
connect the components directly anyways) there's not much else we can
do.
This commit is contained in:
Robbert van der Helm
2020-12-25 14:20:37 +01:00
parent fbad4a65ab
commit 70cb6dad89
9 changed files with 175 additions and 95 deletions
+19 -4
View File
@@ -94,8 +94,17 @@ bool Vst3Logger::log_request(bool is_host_vst,
const YaConnectionPoint::Connect& request) {
return log_request_base(is_host_vst, [&](auto& message) {
message << request.instance_id
<< ": IConnectionPoint::connect(other = <IConnectionPoint* #"
<< request.other_instance_id << ">)";
<< ": IConnectionPoint::connect(other = ";
std::visit(
overload{[&](const native_size_t& other_instance_id) {
message << "<IConnectionPoint* #" << other_instance_id
<< ">";
},
[&](const Vst3ConnectionPointProxy::ConstructArgs&) {
message << "<IConnectionPoint* proxy>";
}},
request.other);
message << ")";
});
}
@@ -103,8 +112,14 @@ bool Vst3Logger::log_request(bool is_host_vst,
const YaConnectionPoint::Disconnect& request) {
return log_request_base(is_host_vst, [&](auto& message) {
message << request.instance_id
<< ": IConnectionPoint::disconnect(other = <IConnectionPoint* #"
<< request.other_instance_id << ">)";
<< ": IConnectionPoint::disconnect(other = ";
if (request.other_instance_id) {
message << "<IConnectionPoint* #" << *request.other_instance_id
<< ">";
} else {
message << "<IConnectionPoint* proxy>";
}
message << ")";
});
}