diff options
Diffstat (limited to 'libs/evoral/evoral')
-rw-r--r-- | libs/evoral/evoral/ControlList.hpp | 6 | ||||
-rw-r--r-- | libs/evoral/evoral/ControlSet.hpp | 5 | ||||
-rw-r--r-- | libs/evoral/evoral/Sequence.hpp | 7 |
3 files changed, 12 insertions, 6 deletions
diff --git a/libs/evoral/evoral/ControlList.hpp b/libs/evoral/evoral/ControlList.hpp index 5f842775ee..d207c76925 100644 --- a/libs/evoral/evoral/ControlList.hpp +++ b/libs/evoral/evoral/ControlList.hpp @@ -218,6 +218,7 @@ public: bool rt_safe_earliest_event (double start, double end, double& x, double& y, bool start_inclusive=false) const; bool rt_safe_earliest_event_unlocked (double start, double end, double& x, double& y, bool start_inclusive=false) const; + bool rt_safe_earliest_event_discrete_unlocked (double start, double end, double& x, double& y, bool inclusive) const; void create_curve(); void destroy_curve(); @@ -234,10 +235,12 @@ public: }; InterpolationStyle interpolation() const { return _interpolation; } - void set_interpolation(InterpolationStyle style) { _interpolation = style; } + void set_interpolation (InterpolationStyle); /** Emitted when mark_dirty() is called on this object */ mutable PBD::Signal0<void> Dirty; + /** Emitted when our interpolation style changes */ + PBD::Signal1<void, InterpolationStyle> InterpolationChanged; protected: @@ -246,7 +249,6 @@ protected: void build_search_cache_if_necessary(double start, double end) const; - bool rt_safe_earliest_event_discrete_unlocked (double start, double end, double& x, double& y, bool inclusive) const; bool rt_safe_earliest_event_linear_unlocked (double start, double end, double& x, double& y, bool inclusive) const; boost::shared_ptr<ControlList> cut_copy_clear (double, double, int op); diff --git a/libs/evoral/evoral/ControlSet.hpp b/libs/evoral/evoral/ControlSet.hpp index b775bb3b4b..95de58dead 100644 --- a/libs/evoral/evoral/ControlSet.hpp +++ b/libs/evoral/evoral/ControlSet.hpp @@ -27,11 +27,11 @@ #include "pbd/signals.h" #include "evoral/types.hpp" #include "evoral/Parameter.hpp" +#include "evoral/ControlList.hpp" namespace Evoral { class Control; -class ControlList; class ControlEvent; class ControlSet : public boost::noncopyable { @@ -69,12 +69,15 @@ public: protected: virtual void control_list_marked_dirty () {} + virtual void control_list_interpolation_changed (Parameter, ControlList::InterpolationStyle) {} mutable Glib::Mutex _control_lock; Controls _controls; private: + PBD::ScopedConnectionList _control_connections; + PBD::ScopedConnectionList _list_connections; }; diff --git a/libs/evoral/evoral/Sequence.hpp b/libs/evoral/evoral/Sequence.hpp index 3cddeb38ca..24a3c44625 100644 --- a/libs/evoral/evoral/Sequence.hpp +++ b/libs/evoral/evoral/Sequence.hpp @@ -185,7 +185,7 @@ public: class const_iterator { public: const_iterator(); - const_iterator(const Sequence<Time>& seq, Time t, std::set<Evoral::Parameter> const &); + const_iterator(const Sequence<Time>& seq, Time t, bool, std::set<Evoral::Parameter> const &); ~const_iterator(); inline bool valid() const { return !_is_end && _event; } @@ -220,10 +220,11 @@ public: typename SysExes::const_iterator _sysex_iter; ControlIterators _control_iters; ControlIterators::iterator _control_iter; + bool _force_discrete; }; - const_iterator begin (Time t=0, std::set<Evoral::Parameter> const & f = std::set<Evoral::Parameter> ()) const { - return const_iterator (*this, t, f); + const_iterator begin (Time t = 0, bool force_discrete = false, std::set<Evoral::Parameter> const & f = std::set<Evoral::Parameter> ()) const { + return const_iterator (*this, t, force_discrete, f); } const const_iterator& end() const { return _end_iter; } |