reserve space for tempo map grid (GUI side)

This commit is contained in:
Paul Davis 2023-07-12 13:08:49 -06:00
parent 81384537ef
commit ed869da97e
2 changed files with 2 additions and 0 deletions

View File

@ -4253,6 +4253,7 @@ Editor::update_grid ()
hide_grid_lines ();
} else if (grid_musical()) {
Temporal::TempoMapPoints grid;
grid.reserve (4096);
if (bbt_ruler_scale != bbt_show_many) {
compute_current_bbt_points (grid, _leftmost_sample, _leftmost_sample + current_page_samples());
}

View File

@ -1193,6 +1193,7 @@ Editor::metric_get_bbt (std::vector<ArdourCanvas::Ruler::Mark>& marks, int64_t l
const samplecnt_t sr (_session->sample_rate());
Temporal::TempoMapPoints grid;
grid.reserve (4096);
compute_current_bbt_points (grid, lower, upper);