diff options
author | David Robillard <d@drobilla.net> | 2008-09-22 16:28:02 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2008-09-22 16:28:02 +0000 |
commit | a2d2f738cb63dbf0fb89e0a00c424ce883fb7888 (patch) | |
tree | 8ff8b9067a8884566b023de2dabedc2b57b856ab /libs/ardour/ardour/automatable.h | |
parent | ff2d51ddd8288ec967efab2cb8192f43c893909e (diff) |
Move event specific ringbuffer stuff to evoral.
Sane event type interface between evoral and libardour (no more shared magic numbers).
Cleanup Evoral::Sequence iterator, fix bugs, probably introduce new ones.
Move MIDI specific event functions to Evoral::MIDIEvent (is-a Evoral::Event).
git-svn-id: svn://localhost/ardour2/branches/3.0@3785 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/ardour/automatable.h')
-rw-r--r-- | libs/ardour/ardour/automatable.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/libs/ardour/ardour/automatable.h b/libs/ardour/ardour/automatable.h index 837bbbc617..dbce7de0bf 100644 --- a/libs/ardour/ardour/automatable.h +++ b/libs/ardour/ardour/automatable.h @@ -27,6 +27,7 @@ #include <ardour/automation_list.h> #include <ardour/automation_control.h> #include <ardour/parameter.h> +#include <ardour/event_type_map.h> #include <evoral/ControlSet.hpp> #include <evoral/Sequence.hpp> @@ -53,9 +54,6 @@ public: virtual void add_control(boost::shared_ptr<Evoral::Control>); virtual void automation_snapshot(nframes_t now, bool force); - bool should_snapshot (nframes_t now) { - return (_last_automation_snapshot > now || (now - _last_automation_snapshot) > _automation_interval); - } virtual void transport_stopped(nframes_t now); virtual string describe_parameter(Parameter param); @@ -73,6 +71,11 @@ public: void mark_automation_visible(Parameter, bool); + inline bool should_snapshot (nframes_t now) { + return (_last_automation_snapshot > now + || (now - _last_automation_snapshot) > _automation_interval); + } + static void set_automation_interval (jack_nframes_t frames) { _automation_interval = frames; } @@ -113,7 +116,7 @@ public: AutomatableSequence(Session& s, size_t size) : Evoral::ControlSet() , Automatable(s) - , Evoral::Sequence(size) + , Evoral::Sequence(EventTypeMap::instance()) {} }; |