diff options
author | Robin Gareus <robin@gareus.org> | 2014-06-07 17:43:12 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2014-06-07 17:43:12 +0200 |
commit | 94fa9278614557effadb5fea8a2387ea29d1cdb6 (patch) | |
tree | 9a22571b2844dcecfe237d8a4ee9c7712ed5ca50 /libs/evoral/src/ControlList.cpp | |
parent | 8f17b7c3091e87544766741668e5aa9410458079 (diff) |
limit automation event density - fixes #5928
Constrain control points to one per tick (1/1920 beats).
Prior to this it was possible to set two values to the
same time (interpolation and iteration failed).
Diffstat (limited to 'libs/evoral/src/ControlList.cpp')
-rw-r--r-- | libs/evoral/src/ControlList.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libs/evoral/src/ControlList.cpp b/libs/evoral/src/ControlList.cpp index 4b7704fff1..e507318214 100644 --- a/libs/evoral/src/ControlList.cpp +++ b/libs/evoral/src/ControlList.cpp @@ -1446,7 +1446,13 @@ ControlList::rt_safe_earliest_event_linear_unlocked (double start, double& x, do assert(inclusive ? x >= start : x > start); return true; } else { - return false; + if (inclusive) { + x = next->when; + } else { + x = start; + } + _search_cache.left = x; + return true; } /* No points in the future, so no steps (towards them) in the future */ |