diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2012-07-13 21:05:45 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2012-07-13 21:05:45 +0000 |
commit | 0532e2063b73ec32d4dd108b58e90a0f20ae91b3 (patch) | |
tree | f9728e4b57f260fd5d468a9c3dd2b2dd2d97e7d7 /libs/evoral/evoral | |
parent | b04cd7d7045dd40a1e3ae819ad3a2f9bb08a01f1 (diff) |
dramatic overhaul of automation. too long to explain here. this work is not finished - write/touch passes do not correctly overwrite existing data because the semantics of ControlList::insert_iterator need clarification. more to follow
git-svn-id: svn://localhost/ardour2/branches/3.0@13038 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/evoral/evoral')
-rw-r--r-- | libs/evoral/evoral/ControlList.hpp | 28 | ||||
-rw-r--r-- | libs/evoral/evoral/ControlSet.hpp | 2 | ||||
-rw-r--r-- | libs/evoral/evoral/types.hpp | 1 |
3 files changed, 13 insertions, 18 deletions
diff --git a/libs/evoral/evoral/ControlList.hpp b/libs/evoral/evoral/ControlList.hpp index 1e546e04fa..c6127a4e9b 100644 --- a/libs/evoral/evoral/ControlList.hpp +++ b/libs/evoral/evoral/ControlList.hpp @@ -124,10 +124,8 @@ public: virtual bool clamp_value (double& /*when*/, double& /*value*/) const { return true; } - void rt_add (double when, double value); - void add (double when, double value); + void add (double when, double value, bool erase_since_last_add = false); void fast_simple_add (double when, double value); - void merge_nascent (double when); void erase_range (double start, double end); void erase (iterator); @@ -245,6 +243,7 @@ public: virtual bool touching() const { return false; } virtual bool writing() const { return false; } virtual bool touch_enabled() const { return false; } + void start_write_pass (double time); void write_pass_finished (double when); /** Emitted when mark_dirty() is called on this object */ @@ -257,6 +256,8 @@ public: bool operator!= (ControlList const &) const; + void invalidate_insert_iterator (); + protected: /** Called by unlocked_eval() to handle cases of 3 or more control points. */ @@ -287,21 +288,14 @@ protected: Curve* _curve; - struct NascentInfo { - EventList events; - double start_time; - double end_time; - double same_value_cnt; - - NascentInfo (double start = -1.0) - : start_time (start) - , end_time (-1.0) - , same_value_cnt (0) - {} - }; - - std::list<NascentInfo*> nascent; static double _thinning_factor; + + private: + iterator insert_iterator; + double insert_position; + bool new_write_pass; + bool did_write_during_pass; + void unlocked_invalidate_insert_iterator (); }; } // namespace Evoral diff --git a/libs/evoral/evoral/ControlSet.hpp b/libs/evoral/evoral/ControlSet.hpp index 293d411755..8df942b31f 100644 --- a/libs/evoral/evoral/ControlSet.hpp +++ b/libs/evoral/evoral/ControlSet.hpp @@ -38,7 +38,7 @@ class ControlSet : public boost::noncopyable { public: ControlSet(); ControlSet (const ControlSet&); - virtual ~ControlSet() {} + virtual ~ControlSet() {} virtual boost::shared_ptr<Evoral::Control> control_factory(const Evoral::Parameter& id) = 0; diff --git a/libs/evoral/evoral/types.hpp b/libs/evoral/evoral/types.hpp index 35dec6de0b..7bdbdc7a2e 100644 --- a/libs/evoral/evoral/types.hpp +++ b/libs/evoral/evoral/types.hpp @@ -52,6 +52,7 @@ namespace PBD { namespace DEBUG { extern uint64_t Sequence; extern uint64_t Note; + extern uint64_t ControlList; } } |