X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Ftest%2Fframepos_plus_beats_test.cc;h=a82415ac2338c6c58274da2a92505bd885ea5f6d;hb=074db3b861926012e9434fe15135ac401da6cb5c;hp=442c9b3d5645874f7b5d4e6163006aef83c12471;hpb=2d649ceac1633b3ea7d770a13944c7b6a1161e9b;p=ardour.git diff --git a/libs/ardour/test/framepos_plus_beats_test.cc b/libs/ardour/test/framepos_plus_beats_test.cc index 442c9b3d56..a82415ac23 100644 --- a/libs/ardour/test/framepos_plus_beats_test.cc +++ b/libs/ardour/test/framepos_plus_beats_test.cc @@ -21,8 +21,8 @@ FrameposPlusBeatsTest::singleTempoTest () Tempo tempo (bpm); Meter meter (4, 4); - map.add_meter (meter, BBT_Time (1, 1, 0)); - map.add_tempo (tempo, BBT_Time (1, 1, 0), TempoSection::TempoSectionType::Constant); + map.add_meter (meter, 0.0, BBT_Time (1, 1, 0), 0, AudioTime); + map.add_tempo (tempo, 0.0, 0, TempoSection::Constant, AudioTime); /* Add 1 beat to beat 3 of the first bar */ framepos_t r = map.framepos_plus_beats (frames_per_beat * 2, Evoral::Beats(1)); @@ -41,7 +41,7 @@ FrameposPlusBeatsTest::doubleTempoTest () TempoMap map (sampling_rate); Meter meter (4, 4); - map.add_meter (meter, BBT_Time (1, 1, 0)); + map.add_meter (meter, 0.0, BBT_Time (1, 1, 0), 0, AudioTime); /* 120bpm at bar 1, 240bpm at bar 4 @@ -56,15 +56,16 @@ FrameposPlusBeatsTest::doubleTempoTest () 120bpm 240bpm 0 beats 12 beats 0 frames 288e3 frames + 0 pulses 4 pulses | | | | | | 1.1 1.2 1.3 1.4 | 2.1 2.2 2.3.2.4 | 3.1 3.2 3.3 3.4 | 4.1 4.2 4.3 4.4 | */ Tempo tempoA (120); - map.add_tempo (tempoA, BBT_Time (1, 1, 0), TempoSection::TempoSectionType::Constant); + map.add_tempo (tempoA, 0.0, 0, TempoSection::Constant, AudioTime); Tempo tempoB (240); - map.add_tempo (tempoB, BBT_Time (4, 1, 0), TempoSection::TempoSectionType::Constant); + map.add_tempo (tempoB, 12.0 / tempoA.note_type(), 0, TempoSection::Constant, MusicTime); /* Now some tests */ @@ -93,7 +94,7 @@ FrameposPlusBeatsTest::doubleTempoWithMeterTest () TempoMap map (sampling_rate); Meter meterA (4, 4); - map.add_meter (meterA, BBT_Time (1, 1, 0)); + map.add_meter (meterA, 0.0, BBT_Time (1, 1, 0), 0, AudioTime); /* 120bpm at bar 1, 240bpm at bar 4 @@ -108,17 +109,18 @@ FrameposPlusBeatsTest::doubleTempoWithMeterTest () 120bpm 240bpm 0 beats 12 beats 0 frames 288e3 frames + 0 pulses 4 pulses | | | | | | 1.1 1.2 1.3 1.4 | 2.1 2.2 2.3.2.4 | 3.1 3.2 3.3 3.4 | 4.1 4.2 4.3 | */ Tempo tempoA (120); - map.add_tempo (tempoA, BBT_Time (1, 1, 0), TempoSection::TempoSectionType::Constant); + map.add_tempo (tempoA, 0.0, 0, TempoSection::Constant, AudioTime); Tempo tempoB (240); - map.add_tempo (tempoB, BBT_Time (4, 1, 0), TempoSection::TempoSectionType::Constant); + map.add_tempo (tempoB, 12.0 / tempoA.note_type(), 0, TempoSection::Constant, MusicTime); Meter meterB (3, 4); - map.add_meter (meterB, BBT_Time (4, 1, 0)); + map.add_meter (meterB, 12.0 / tempoA.note_type(), BBT_Time (4, 1, 0), 0, MusicTime); /* Now some tests */