summaryrefslogtreecommitdiff
path: root/plugin
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2017-10-14 17:50:01 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2018-02-18 11:43:41 +0100
commit6a90e6c24f05c57cdbe19e5cc44c77c9e5810148 (patch)
treed90fab1ab3bc5aa421ca671990590f9ded391709 /plugin
parent0dc69ba161bb0c8fce2eb0ab3c5eb897f7aa92a7 (diff)
Added plugin store/restore of latency filter settings, added the missing settings to the lv2 unittest and added the missing SettingsGetter and SettingsNotifier parts.
Diffstat (limited to 'plugin')
-rw-r--r--plugin/drumgizmo_plugin.cc35
1 files changed, 35 insertions, 0 deletions
diff --git a/plugin/drumgizmo_plugin.cc b/plugin/drumgizmo_plugin.cc
index c8d8392..90db744 100644
--- a/plugin/drumgizmo_plugin.cc
+++ b/plugin/drumgizmo_plugin.cc
@@ -571,6 +571,16 @@ std::string DrumGizmoPlugin::ConfigStringIO::get()
bool2str(settings.enable_bleed_control.load()) + "</value>\n"
" <value name=\"master_bleed\">" +
float2str(settings.master_bleed.load()) + "</value>\n"
+ " <value name=\"enable_latency_modifier\">" +
+ bool2str(settings.enable_latency_modifier.load()) + "</value>\n"
+ " <value name=\"latency_max\">" +
+ int2str(settings.latency_max.load()) + "</value>\n"
+ " <value name=\"latency_laid_back\">" +
+ int2str(settings.latency_laid_back.load()) + "</value>\n"
+ " <value name=\"latency_stddev\">" +
+ float2str(settings.latency_stddev.load()) + "</value>\n"
+ " <value name=\"latency_regain\">" +
+ float2str(settings.latency_regain.load()) + "</value>\n"
"</config>";
}
@@ -645,6 +655,31 @@ bool DrumGizmoPlugin::ConfigStringIO::set(std::string config_string)
settings.master_bleed.store(str2float(p.value("master_bleed")));
}
+ if(p.value("enable_latency_modifier") != "")
+ {
+ settings.enable_latency_modifier.store(p.value("enable_latency_modifier") == "true");
+ }
+
+ if(p.value("latency_max") != "")
+ {
+ settings.latency_max.store(str2int(p.value("latency_max")));
+ }
+
+ if(p.value("latency_laid_back") != "")
+ {
+ settings.latency_laid_back.store(str2int(p.value("latency_laid_back")));
+ }
+
+ if(p.value("latency_stddev") != "")
+ {
+ settings.latency_stddev.store(str2float(p.value("latency_stddev")));
+ }
+
+ if(p.value("latency_regain") != "")
+ {
+ settings.latency_regain.store(str2float(p.value("latency_regain")));
+ }
+
std::string newkit = p.value("drumkitfile");
if(newkit != "")
{