mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-30 17:03:06 +01:00
added TempoMap::Changed signal
This commit is contained in:
parent
9bc8b32b8e
commit
f9f32cb5be
2 changed files with 9 additions and 0 deletions
|
|
@ -498,6 +498,7 @@ TempoMap::rebuild (superclock_t limit)
|
|||
*/
|
||||
|
||||
bool hit_dirty = false;
|
||||
superclock_t first_dirty = 0;
|
||||
|
||||
for (tmp = _points.begin(); tmp != _points.end(); ) {
|
||||
|
||||
|
|
@ -507,6 +508,7 @@ TempoMap::rebuild (superclock_t limit)
|
|||
continue;
|
||||
}
|
||||
hit_dirty = true;
|
||||
first_dirty = tmp->sclock();
|
||||
}
|
||||
|
||||
TempoMapPoints::iterator next = tmp;
|
||||
|
|
@ -567,6 +569,9 @@ TempoMap::rebuild (superclock_t limit)
|
|||
prev = tmp;
|
||||
tmp = next;
|
||||
}
|
||||
|
||||
Changed (first_dirty, _points.back().sclock()); /* EMIT SIGNAL */
|
||||
cerr << "Rebuilt " << first_dirty << " .. " << _points.back().sclock() << endl;
|
||||
}
|
||||
|
||||
bool
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@
|
|||
|
||||
#include <glibmm/threads.h>
|
||||
|
||||
#include "pbd/signals.h"
|
||||
|
||||
#include "evoral/Beats.hpp"
|
||||
|
||||
#include "ardour/ardour.h"
|
||||
|
|
@ -361,6 +363,8 @@ class LIBARDOUR_API TempoMap
|
|||
void dump (std::ostream&);
|
||||
void rebuild (superclock_t limit);
|
||||
|
||||
PBD::Signal2<void,superclock_t,superclock_t> Changed;
|
||||
|
||||
private:
|
||||
TempoMapPoints _points;
|
||||
framecnt_t _sample_rate;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue