mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-11 09:06:33 +01:00
more tweaks to correctly (or more correctly) reload disk reader buffers when loop fade choice changes
This commit is contained in:
parent
1a2665e25f
commit
d04c9b3244
3 changed files with 12 additions and 6 deletions
|
|
@ -794,6 +794,8 @@ DiskReader::audio_read (PBD::PlaybackBuffer<Sample>*rb,
|
||||||
|
|
||||||
/* Looping: do something (maybe) about the loop boundaries */
|
/* Looping: do something (maybe) about the loop boundaries */
|
||||||
|
|
||||||
|
cerr << name() << " Read with lfc = " << enum_2_string (Config->get_loop_fade_choice()) << endl;
|
||||||
|
|
||||||
switch (Config->get_loop_fade_choice()) {
|
switch (Config->get_loop_fade_choice()) {
|
||||||
case NoLoopFade:
|
case NoLoopFade:
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
|
|
@ -1415,16 +1415,16 @@ Session::auto_loop_changed (Location* location)
|
||||||
|
|
||||||
const bool rolling = transport_rolling ();
|
const bool rolling = transport_rolling ();
|
||||||
|
|
||||||
|
boost::shared_ptr<RouteList> r = routes.reader ();
|
||||||
|
|
||||||
|
for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
|
||||||
|
(*i)->reload_loop ();
|
||||||
|
}
|
||||||
|
|
||||||
if (rolling) {
|
if (rolling) {
|
||||||
|
|
||||||
if (play_loop) {
|
if (play_loop) {
|
||||||
|
|
||||||
boost::shared_ptr<RouteList> r = routes.reader ();
|
|
||||||
|
|
||||||
for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
|
|
||||||
(*i)->reload_loop ();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (_transport_sample < location->start() || _transport_sample > location->end()) {
|
if (_transport_sample < location->start() || _transport_sample > location->end()) {
|
||||||
// new loop range excludes current transport
|
// new loop range excludes current transport
|
||||||
// sample => relocate to beginning of loop and roll.
|
// sample => relocate to beginning of loop and roll.
|
||||||
|
|
|
||||||
|
|
@ -4148,6 +4148,10 @@ Session::config_changed (std::string p, bool ours)
|
||||||
remove_monitor_section ();
|
remove_monitor_section ();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} else if (p == "loop-fade-choice") {
|
||||||
|
cerr << "LFC change, change auto-loop\n";
|
||||||
|
last_loopend = 0; /* force locate to refill buffers with new loop boundary data */
|
||||||
|
auto_loop_changed (_locations->auto_loop_location());
|
||||||
}
|
}
|
||||||
|
|
||||||
set_dirty ();
|
set_dirty ();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue