mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-11 00:56:33 +01:00
Tempo lines drawing performance tweak.
This commit is contained in:
parent
f8d5a6b3b6
commit
115bc84c27
1 changed files with 4 additions and 2 deletions
|
|
@ -103,6 +103,8 @@ TempoLines::draw (std::vector<ARDOUR::TempoMap::BBTPoint>& grid,
|
||||||
|
|
||||||
uint32_t beats = 0;
|
uint32_t beats = 0;
|
||||||
uint32_t bars = 0;
|
uint32_t bars = 0;
|
||||||
|
const uint32_t bar_color = UIConfiguration::instance().color ("measure line bar");
|
||||||
|
const uint32_t beat_color = UIConfiguration::instance().color_mod ("measure line beat", "measure line beat");
|
||||||
uint32_t color;
|
uint32_t color;
|
||||||
|
|
||||||
bool all_bars = false;
|
bool all_bars = false;
|
||||||
|
|
@ -165,12 +167,12 @@ TempoLines::draw (std::vector<ARDOUR::TempoMap::BBTPoint>& grid,
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
color = UIConfiguration::instance().color ("measure line bar");
|
color = bar_color;
|
||||||
} else {
|
} else {
|
||||||
if (beat_density > 0.3) {
|
if (beat_density > 0.3) {
|
||||||
continue; /* only draw beat lines if the gaps between beats are large. */
|
continue; /* only draw beat lines if the gaps between beats are large. */
|
||||||
}
|
}
|
||||||
color = UIConfiguration::instance().color_mod ("measure line beat", "measure line beat");
|
color = beat_color;
|
||||||
}
|
}
|
||||||
|
|
||||||
ArdourCanvas::Coord xpos = PublicEditor::instance().sample_to_pixel_unrounded ((*i).frame);
|
ArdourCanvas::Coord xpos = PublicEditor::instance().sample_to_pixel_unrounded ((*i).frame);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue