diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2007-07-06 03:11:52 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2007-07-06 03:11:52 +0000 |
commit | 1516d52ffab61cb0e117f1829ede387e2d2eb021 (patch) | |
tree | 964442d73efa1774798501936ff9aaab8a370234 /libs/ardour/ardour | |
parent | 65438f0fe4abb11ce0d039f6bbd7cd74696cae9c (diff) |
new automation interval configuration variable, to control automation snapshot time resolution (for oofus to test); patch for cancellingmulti-file import; minor code cleanups; use boost::fast_pool_allocator for automation lists (may revert later)
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@2117 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/ardour')
-rw-r--r-- | libs/ardour/ardour/automation_event.h | 18 | ||||
-rw-r--r-- | libs/ardour/ardour/configuration_vars.h | 1 |
2 files changed, 16 insertions, 3 deletions
diff --git a/libs/ardour/ardour/automation_event.h b/libs/ardour/ardour/automation_event.h index 007bad7259..7db5e3f459 100644 --- a/libs/ardour/ardour/automation_event.h +++ b/libs/ardour/ardour/automation_event.h @@ -24,6 +24,9 @@ #include <list> #include <cmath> +#include <boost/pool/pool.hpp> +#include <boost/pool/pool_alloc.hpp> + #include <sigc++/signal.h> #include <glibmm/thread.h> @@ -35,7 +38,8 @@ namespace ARDOUR { -struct ControlEvent { +class ControlEvent { + public: double when; double value; @@ -49,13 +53,21 @@ struct ControlEvent { // bool operator==(const ControlEvent& other) { // return value == other.value && when == other.when; // } - }; +/* automation lists use a pool allocator that does not use a lock and + allocates 8k of new pointers at a time +*/ + +typedef boost::fast_pool_allocator<ControlEvent, + boost::default_user_allocator_new_delete, + boost::details::pool::null_mutex, + 8192> ControlEventAllocator; + class AutomationList : public PBD::StatefulDestructible { public: - typedef std::list<ControlEvent*> AutomationEventList; + typedef std::list<ControlEvent*,ControlEventAllocator> AutomationEventList; typedef AutomationEventList::iterator iterator; typedef AutomationEventList::const_iterator const_iterator; diff --git a/libs/ardour/ardour/configuration_vars.h b/libs/ardour/ardour/configuration_vars.h index 61dc1bd225..f532056b85 100644 --- a/libs/ardour/ardour/configuration_vars.h +++ b/libs/ardour/ardour/configuration_vars.h @@ -141,6 +141,7 @@ CONFIG_VARIABLE (uint32_t, saved_history_depth, "save-history-depth", 100) CONFIG_VARIABLE (bool, use_overlap_equivalency, "use-overlap-equivalency", false) CONFIG_VARIABLE (bool, periodic_safety_backups, "periodic-safety-backups", true) CONFIG_VARIABLE (uint32_t, periodic_safety_backup_interval, "periodic-safety-backup-interval", 120) +CONFIG_VARIABLE (float, automation_interval, "automation-interval", 50) /* denormal management */ |