Commit graph

17719 commits

Author SHA1 Message Date
Paul Davis
0ce40fc648 Temporal: fix timepos_t (Beats) constructor
flag bit was set incorrectly
2021-08-13 12:51:31 -06:00
Paul Davis
a01bb90c04 libardour: remove _length_beats member from MidiSource and use Source::_length
timecnt_t can represent either time domain
2021-08-13 12:51:31 -06:00
Paul Davis
9e58c43ecd libardour: change flow control to return early rather than use condition scope in Region::set_length() 2021-08-13 12:51:31 -06:00
Paul Davis
9ca376c232 libardour: fix another NUTEMPO warning by replacing a BeatSamplesConverter with timecnt_t 2021-08-13 12:51:31 -06:00
Paul Davis
170541deb7 libpbd: fix implementation of int62_t::operator== and ::operator!=
Reversed logic error
2021-08-13 12:51:31 -06:00
Paul Davis
747281a244 Temporal: fix implementation of timecnt_t::operator= (timecnt_t const &)
It is OK now to have inconsistent time domains inside a timecnt_t
2021-08-13 12:51:31 -06:00
Paul Davis
3900537fcf split Beats::round_to_subdivision() into source module
Rounding to bar requires access to the tempo map, and we don't want this in
the beats.h header
2021-08-13 12:51:31 -06:00
Paul Davis
0d15797499 small cleanup to Source length API 2021-08-13 12:51:31 -06:00
Paul Davis
6c6d7fa874 fix 2 NUTEMPO #warnings in smf_source.cc 2021-08-13 12:51:31 -06:00
Paul Davis
d995a07011 remove AutomationList::paste since it is no longer required (just use ControlList::paste()) 2021-08-13 12:51:31 -06:00
Paul Davis
779a04b0ce Evoral: alter ControlList::paste() to internally change time domain of pasted events 2021-08-13 12:51:31 -06:00
Paul Davis
c64db47b37 use new libtemporal sample rate mechanism (libs edition) 2021-08-13 12:51:31 -06:00
Paul Davis
5bef968069 Temporal: replace thread_local sample rate with callback to get sample rate 2021-08-13 12:51:31 -06:00
Paul Davis
6e9f57d2ad Temporal: remove scope braces left over from when we used a lock to protect the tempo map 2021-08-13 12:51:31 -06:00
Paul Davis
b6f2e39ed4 Temporal: remove BarTime 2021-08-13 12:51:31 -06:00
Paul Davis
5987376afc Temporal: avoid recursive descent in TempoMap::quarters_at (timepos_t) 2021-08-13 12:51:31 -06:00
Paul Davis
3ca2be321d use cleaned up Temporal ::quarters*_at* API (libs edition) 2021-08-13 12:51:31 -06:00
Paul Davis
43d84620e0 Temporal: clean up API to remove ambiguity about ::quarter*_at_*
superclock_t and samplepos_t have the same underlying C++ type, so methods that accept one or the
other as an argument need to be named to make it clear which type they accept. We do not need
the superclock_t variant publically, but it turns out to be useful within TempoMap.
2021-08-13 12:51:31 -06:00
Paul Davis
bed76798f3 manual fixups after rebase against master (general libs edition) 2021-08-13 12:51:31 -06:00
Paul Davis
c76c61d202 manual fixups after rebase against master 2021-08-13 12:51:31 -06:00
Paul Davis
fe218e7478 nutempo-ify VST support (incomplete, pending change to tempo map API 2021-08-13 12:51:31 -06:00
Paul Davis
fbdf06a794 cleanup after timecnt_t API changed (libs edition) 2021-08-13 12:51:31 -06:00
Paul Davis
afea443419 remove API from Temporal:timecnt_t that used superclock_t
Not possible for a compiler to differentiate superclock_t and sample(pos|cnt)_t, which can lead to
subtle but major errors
2021-08-13 12:51:31 -06:00
Paul Davis
9402548677 Temporal: add lots more DEBUG::TemporalMap output to tempo.cc 2021-08-13 12:51:31 -06:00
Paul Davis
793579cf3f Temporal: expand displayed info for Tempo's operator<< 2021-08-13 12:51:31 -06:00
Paul Davis
a0b9030e3c Temporal: fix logic during ::get_grid that ignored if rounding did nothing 2021-08-13 12:51:31 -06:00
Paul Davis
f1bb135013 Temporal: fix computation of ::quarters_at() 2021-08-13 12:51:31 -06:00
Paul Davis
7085dccebc Temporal: make Tempo:: super_note_type_per_second publically accessible 2021-08-13 12:51:31 -06:00
Paul Davis
12b967afca use ::empty() not ::distance (a,b) == 0 (wierd construction!) 2021-08-13 12:51:31 -06:00
Paul Davis
c3e12672b2 fix use of ::add_click (samplepos_t) when doing clicks (i.e. no superclock here) 2021-08-13 12:51:31 -06:00
Paul Davis
11af6253f5 mackie: NOOP: fix whitespace 2021-08-13 12:51:31 -06:00
Paul Davis
18fea5c7a9 changes required by fixing ambiguities in timepos_t/timecnt_t API (evoral edition) 2021-08-13 12:51:31 -06:00
Paul Davis
65aa619e58 changes required by fixing ambiguities in timepos_t/timecnt_t API (libs edition) 2021-08-13 12:51:31 -06:00
Paul Davis
c3d325b56a Temporal: clean up API for timepos_t to remove unneeded duplicates and remove ambiguity 2021-08-13 12:51:31 -06:00
Paul Davis
52ddf91e5b Temporal: explain with timepos_t::_{ticks,beats} are for 2021-08-13 12:51:31 -06:00
Paul Davis
5887ee524e Temporal: further improvements to a timepos_t::distance() method 2021-08-13 12:51:31 -06:00
Paul Davis
7b0d812e92 fix thinko with incorrect argument to AudioRegion::region_from_sources() 2021-08-13 12:51:31 -06:00
Paul Davis
7c56b9b2fc Temporal: fix insanely incorrect implementation of timepos_t::distance() 2021-08-13 12:51:30 -06:00
Paul Davis
b866335d8f add glib event loop callback to Generic MIDI surface support 2021-08-13 12:51:30 -06:00
Paul Davis
def35cf043 mark BBT_Offset (double) constructor explicit to avoid implicit conversion in timeline expressions.
Also clean up the mess this had caused.
2021-08-13 12:51:30 -06:00
Paul Davis
b01b6929fb fix potential for overflow when converting larger sample counts to superclock.
int_div_rount<T> was using int (32 bits) which could overflow.
2021-08-13 12:51:30 -06:00
Paul Davis
15b28b103a NOOP: whitespace changes 2021-08-13 12:51:30 -06:00
Paul Davis
f8a0ba246c move superclock_ticks_per_second declaration 2021-08-13 12:51:30 -06:00
Paul Davis
82e84e6b92 change all Region::nt_*() methods to names without the nt_ prefix (library version) 2021-08-13 12:51:30 -06:00
Paul Davis
f0008898af add operator<<() for timecnt_t() 2021-08-13 12:51:30 -06:00
Paul Davis
4f6befea83 fix in62_t equality/inequality operators when used with mismatched arguments 2021-08-13 12:51:30 -06:00
Paul Davis
bb9376c2b1 remove #warnings from region.cc related to Source object API 2021-08-13 12:51:30 -06:00
Paul Davis
047cca3815 use AudioEngine sample rate, not session rate, in Graph
They should, of course, be the same, but the session may not be set up fully before the Graph object creates threads
2021-08-13 12:51:30 -06:00
Paul Davis
b876baa757 Temporal: various changes to arithmetic/logic methods to avoid assert() on domain mismatches where none is really needed 2021-08-13 12:51:30 -06:00
Paul Davis
baaa8f36ca fix timepos_t::max and timecnt_t::max to avoid int62_t flag bit
Both should likely just re-use int62_t::max
2021-08-13 12:51:30 -06:00