From 0532e2063b73ec32d4dd108b58e90a0f20ae91b3 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Fri, 13 Jul 2012 21:05:45 +0000 Subject: 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 --- libs/ardour/automation_list.cc | 27 +++++---------------------- 1 file changed, 5 insertions(+), 22 deletions(-) (limited to 'libs/ardour/automation_list.cc') diff --git a/libs/ardour/automation_list.cc b/libs/ardour/automation_list.cc index 26ca7b097a..39e7bacc46 100644 --- a/libs/ardour/automation_list.cc +++ b/libs/ardour/automation_list.cc @@ -180,11 +180,6 @@ AutomationList::set_automation_state (AutoState s) { if (s != _state) { _state = s; - - if (_state == Write) { - Glib::Mutex::Lock lm (ControlList::_lock); - nascent.push_back (new NascentInfo ()); - } automation_state_changed (s); /* EMIT SIGNAL */ } } @@ -202,8 +197,7 @@ void AutomationList::start_touch (double when) { if (_state == Touch) { - Glib::Mutex::Lock lm (ControlList::_lock); - nascent.push_back (new NascentInfo (when)); + start_write_pass (when); } g_atomic_int_set (&_touching, 1); @@ -223,22 +217,11 @@ AutomationList::stop_touch (bool mark, double when) if (_state == Touch) { - assert (!nascent.empty ()); - - Glib::Mutex::Lock lm (ControlList::_lock); - if (mark) { - - nascent.back()->end_time = when; - - } else { - - /* nascent info created in start touch but never used. just get rid of it. - */ - - NascentInfo* ninfo = nascent.back (); - nascent.erase (nascent.begin()); - delete ninfo; + + /* XXX need to mark the last added point with the + * current time + */ } } } -- cgit v1.2.3