static samplecnt_t default_chunk_samples ();
static void set_chunk_samples (samplecnt_t n) { _chunk_samples = n; }
+ bool can_support_io_configuration (const ChanCount& in, ChanCount& out);
+
void run (BufferSet& /*bufs*/, samplepos_t /*start_sample*/, samplepos_t /*end_sample*/, double speed, pframes_t /*nframes*/, bool /*result_required*/);
void realtime_handle_transport_stopped ();
void realtime_locate (bool);
{
boost::shared_ptr<ChannelList> c = channels.reader();
- if (c->empty ()) {
+ if (c->empty () || !_playlists[DataType::AUDIO]) {
return true;
}
}
}
+
+bool
+DiskReader::can_support_io_configuration (const ChanCount& in, ChanCount& out)
+{
+ if (!DiskIOProcessor::can_support_io_configuration (in, out)) {
+ return false;
+ }
+
+ /* DiskIO might have done this too, but do it again anyway as a
+ * starting point.
+ */
+
+ out == in;
+
+ if (_playlists[DataType::AUDIO]) {
+ ChannelList::size_type naudio = max (ChannelList::size_type (1), channels.reader()->size());
+ if (out.n_audio() < naudio) {
+ out.set (DataType::AUDIO, naudio);
+ }
+ }
+
+ if (_playlists[DataType::MIDI]) {
+ if (out.n_midi() != 1) {
+ out.set (DataType::MIDI, 1);
+ }
+ }
+
+ return true;
+}