From 115083c13de714cb663dfa3ddd63b47b56041024 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sun, 25 Jul 2010 23:19:43 +0000 Subject: Remove end of SearchCache as it is not used (it's always set to DBL_MAX) git-svn-id: svn://localhost/ardour2/branches/3.0@7493 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/evoral/evoral/ControlList.hpp | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'libs/evoral/evoral/ControlList.hpp') diff --git a/libs/evoral/evoral/ControlList.hpp b/libs/evoral/evoral/ControlList.hpp index d207c76925..28b9ba2fcd 100644 --- a/libs/evoral/evoral/ControlList.hpp +++ b/libs/evoral/evoral/ControlList.hpp @@ -193,12 +193,11 @@ public: std::pair range; }; - /** Lookup cache for point finding, range contains points between left and right */ + /** Lookup cache for point finding, range contains points after left */ struct SearchCache { - SearchCache() : left(-1), right(-1) {} - double left; /* leftmost x coordinate used when finding "range" */ - double right; /* rightmost x coordinate used when finding "range" */ - std::pair range; + SearchCache () : left(-1) {} + double left; /* leftmost x coordinate used when finding "first" */ + ControlList::const_iterator first; }; const EventList& events() const { return _events; } @@ -216,9 +215,9 @@ public: */ double unlocked_eval (double x) const; - 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; + bool rt_safe_earliest_event (double start, double& x, double& y, bool start_inclusive=false) const; + bool rt_safe_earliest_event_unlocked (double start, double& x, double& y, bool start_inclusive=false) const; + bool rt_safe_earliest_event_discrete_unlocked (double start, double& x, double& y, bool inclusive) const; void create_curve(); void destroy_curve(); @@ -247,9 +246,9 @@ protected: /** Called by unlocked_eval() to handle cases of 3 or more control points. */ double multipoint_eval (double x) const; - void build_search_cache_if_necessary(double start, double end) const; + void build_search_cache_if_necessary (double start) const; - bool rt_safe_earliest_event_linear_unlocked (double start, double end, double& x, double& y, bool inclusive) const; + bool rt_safe_earliest_event_linear_unlocked (double start, double& x, double& y, bool inclusive) const; boost::shared_ptr cut_copy_clear (double, double, int op); bool erase_range_internal (double start, double end, EventList &); -- cgit v1.2.3