diff options
author | André Nusser <andre.nusser@googlemail.com> | 2018-06-08 22:17:20 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2018-08-12 11:13:49 +0200 |
commit | 2da458423c1fa95d3000d94105f215c6a603094b (patch) | |
tree | 13db7d1b4104a5d3b60c73854d5d26396ba40fc1 /src/settings.h | |
parent | 592f05fa549c7e680e502f569c27e71177361ad6 (diff) |
Add tab for drumkit.
Diffstat (limited to 'src/settings.h')
-rw-r--r-- | src/settings.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/settings.h b/src/settings.h index 5137809..13bb956 100644 --- a/src/settings.h +++ b/src/settings.h @@ -128,6 +128,10 @@ struct Settings // Current latency offset in ms - for UI Atomic<float> latency_current{0}; + + Atomic<std::size_t> audition_counter{0}; + Atomic<std::string> audition_instrument; + Atomic<float> audition_velocity; }; //! Settings getter class. @@ -179,6 +183,10 @@ struct SettingsGetter SettingRef<float> latency_regain; SettingRef<float> latency_current; + SettingRef<std::size_t> audition_counter; + SettingRef<std::string> audition_instrument; + SettingRef<float> audition_velocity; + SettingsGetter(Settings& settings) : drumkit_file(settings.drumkit_file) , drumkit_load_status(settings.drumkit_load_status) @@ -216,6 +224,9 @@ struct SettingsGetter , latency_stddev{settings.latency_stddev} , latency_regain{settings.latency_regain} , latency_current{settings.latency_current} + , audition_counter{settings.audition_counter} + , audition_instrument{settings.audition_instrument} + , audition_velocity{settings.audition_velocity} { } }; @@ -270,6 +281,10 @@ public: Notifier<float> latency_regain; Notifier<float> latency_current; + Notifier<std::size_t> audition_counter; + Notifier<std::string> audition_instrument; + Notifier<int> audition_velocity; + void evaluate() { #define EVAL(x) if(settings.x.hasChanged()) { x(settings.x.getValue()); } @@ -319,6 +334,10 @@ public: EVAL(latency_stddev); EVAL(latency_regain); EVAL(latency_current); + + EVAL(audition_counter); + EVAL(audition_instrument); + EVAL(audition_velocity); } SettingsNotifier(Settings& settings) |