diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2016-04-03 17:40:50 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2016-04-03 17:40:50 +0200 |
commit | b530ac02af61e320e137a392decef1b3cc5af2c4 (patch) | |
tree | ee35fc43b5da94e3f04fec583dadc856102f9254 /src | |
parent | 02784b77bb4f652d362297d947b8305dea2b195a (diff) |
Fix logic error in SettingRef::hasChanged().
Diffstat (limited to 'src')
-rw-r--r-- | src/settings.h | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/src/settings.h b/src/settings.h index 2700e26..b132c1b 100644 --- a/src/settings.h +++ b/src/settings.h @@ -31,30 +31,16 @@ #include <cassert> #include "atomic.h" -//bool Conf::enable_velocity_modifier = true; -//float Conf::velocity_modifier_falloff = 0.5; -//float Conf::velocity_modifier_weight = 0.25; -// -//bool Conf::enable_velocity_randomiser = false; -//float Conf::velocity_randomiser_weight = 0.1; -// -//int Conf::samplerate = 44100; -// -//bool Conf::enable_resampling = true; - -//operator Atomic<bool> //! Engine settings struct Settings { - Atomic<std::string> foo{"foo"}; - Atomic<bool> enable_velocity_modifier{true}; - Atomic<float> velocity_modifier_falloff{0.5}; - Atomic<float> velocity_modifier_weight{0.25}; + Atomic<float> velocity_modifier_falloff{0.5f}; + Atomic<float> velocity_modifier_weight{0.25f}; Atomic<bool> enable_velocity_randomiser{false}; - Atomic<float> velocity_randomiser_weight{0.1}; + Atomic<float> velocity_randomiser_weight{0.1f}; Atomic<double> samplerate{44100.0}; @@ -87,7 +73,7 @@ public: return true; } - return tmp == cache; + return tmp != cache; } T getValue() const |