From d6e8ec3c4a808b4eb3c90f9a72bfa6e12993e977 Mon Sep 17 00:00:00 2001 From: Jonathan Moore Liles Date: Wed, 14 May 2008 18:47:28 -0500 Subject: [PATCH] Make time points reset the beat count. --- Timeline/Timeline.C | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Timeline/Timeline.C b/Timeline/Timeline.C index fd14bed..e1b36dd 100644 --- a/Timeline/Timeline.C +++ b/Timeline/Timeline.C @@ -366,6 +366,7 @@ const float ticks_per_beat = 1920.0; void Timeline::update_tempomap ( void ) { + /* FIXME: we need some type of locking! */ _tempomap.clear(); for ( list ::const_iterator i = time_track->_widgets.begin(); @@ -387,11 +388,11 @@ Timeline::solve_tempomap ( nframes_t frame ) const return render_tempomap( frame, 0, 0, 0 ); } +/* THREAD: UI and RT */ /** draw appropriate measure lines inside the given bounding box */ position_info Timeline::render_tempomap( nframes_t start, nframes_t length, measure_line_callback * cb, void *arg ) const { - const nframes_t end = start + length; position_info pos; @@ -431,6 +432,9 @@ Timeline::render_tempomap( nframes_t start, nframes_t length, measure_line_callb const Time_Point *p = (Time_Point*)(*i); sig = p->time(); + + /* Time point resets beat */ + bbt.beat = 0; } {