mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-14 20:40:03 +02:00
Redesign how interface instantiation works
Transferring some argument pack is much easier than trying to deserialize into an existing object when you also have to transfer more information than just that object.
This commit is contained in:
@@ -56,20 +56,26 @@ void Vst3Logger::log_request(bool is_host_vst, const WantsPluginFactory&) {
|
||||
}
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst, const Configuration&) {
|
||||
void Vst3Logger::log_response(
|
||||
bool is_host_vst,
|
||||
const std::optional<YaComponent::Arguments>& args) {
|
||||
if (BOOST_UNLIKELY(logger.verbosity >= Logger::Verbosity::most_events)) {
|
||||
std::ostringstream message;
|
||||
message << get_log_prefix(is_host_vst) << " <Configuration>";
|
||||
if (args) {
|
||||
message << get_log_prefix(is_host_vst) << " <IComponent* #"
|
||||
<< args->instance_id << ">";
|
||||
} else {
|
||||
message << get_log_prefix(is_host_vst) << " <nullptr>";
|
||||
}
|
||||
|
||||
log(message.str());
|
||||
}
|
||||
}
|
||||
|
||||
void Vst3Logger::log_response(bool is_host_vst, const YaComponent&) {
|
||||
void Vst3Logger::log_response(bool is_host_vst, const Configuration&) {
|
||||
if (BOOST_UNLIKELY(logger.verbosity >= Logger::Verbosity::most_events)) {
|
||||
std::ostringstream message;
|
||||
// TODO: Add the instance ID after we implement that
|
||||
message << get_log_prefix(is_host_vst) << " <IComponent*>";
|
||||
message << get_log_prefix(is_host_vst) << " <Configuration>";
|
||||
|
||||
log(message.str());
|
||||
}
|
||||
|
||||
@@ -49,8 +49,9 @@ class Vst3Logger {
|
||||
void log_request(bool is_host_vst, const WantsConfiguration&);
|
||||
void log_request(bool is_host_vst, const WantsPluginFactory&);
|
||||
|
||||
void log_response(bool is_host_vst,
|
||||
const std::optional<YaComponent::Arguments>&);
|
||||
void log_response(bool is_host_vst, const Configuration&);
|
||||
void log_response(bool is_host_vst, const YaComponent&);
|
||||
void log_response(bool is_host_vst, const YaPluginFactory&);
|
||||
|
||||
Logger& logger;
|
||||
|
||||
Reference in New Issue
Block a user