{
// set up capture and playback buffering
Diskstream::set_buffering_parameters (Config->get_buffering_preset());
-
+
/* size is in Samples, not bytes */
const float rate = (float)_session.frame_rate();
audio_dstream_capture_buffer_size = (uint32_t) floor (Config->get_audio_capture_buffer_seconds() * rate);
// we are ready to request buffer adjustments
_session.adjust_capture_buffering ();
_session.adjust_playback_buffering ();
-
+
return 0;
}
}
}
-
+
restart:
DEBUG_TRACE (DEBUG::Butler, "at restart for disk work\n");
disk_work_outstanding = false;
case 0:
DEBUG_TRACE (DEBUG::Butler, string_compose ("\ttrack refill done %1\n", tr->name()));
break;
-
+
case 1:
DEBUG_TRACE (DEBUG::Butler, string_compose ("\ttrack refill unfinished %1\n", tr->name()));
disk_work_outstanding = true;
for (RouteList::iterator i = rl->begin(); !transport_work_requested() && should_run && i != rl->end(); ++i) {
// cerr << "write behind for " << (*i)->name () << endl;
-
+
boost::shared_ptr<Track> tr = boost::dynamic_pointer_cast<Track> (*i);
if (!tr) {
}
return disk_work_outstanding;
-}
+}
bool
Butler::flush_tracks_to_disk_after_locate (boost::shared_ptr<RouteList> rl, uint32_t& errors)
/* almost the same as the "normal" version except that we do not test
* for transport_work_requested() and we force flushes.
*/
-
+
for (RouteList::iterator i = rl->begin(); i != rl->end(); ++i) {
// cerr << "write behind for " << (*i)->name () << endl;
}
return disk_work_outstanding;
-}
+}
void
Butler::schedule_transport_work ()