lines.set_extent (ArdourCanvas::COORD_MAX);
}
+TempoLines::~TempoLines ()
+{
+ delete _bfc;
+ _bfc = 0;
+}
+
void
-TempoLines::tempo_map_changed()
+TempoLines::tempo_map_changed (framepos_t new_origin)
{
lines.clear ();
+ _bfc->set_origin_b (new_origin);
}
void
/* draw line with alpha corresponding to coarsest level */
const uint8_t a = max(8, (int)rint(UINT_RGBA_A(base) / (0.8 * log2(level))));
const uint32_t c = UINT_RGBA_CHANGE_A(base, a);
- const framepos_t f = _bfc->to (Evoral::Beats (grid.begin()->qn + (l / (double) divisions)));
+ const framepos_t f = _bfc->to (Evoral::Beats (grid.begin()->qn + (l / (double) divisions))) + _bfc->origin_b();
if (f > leftmost_frame) {
lines.add (PublicEditor::instance().sample_to_pixel_unrounded (f), 1.0, c);