From 8efaca01efcdb1c7606d3f2aa18e875fd7a26244 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 30 Jun 2010 00:11:27 +0000 Subject: Fix starting scratch buffer count. git-svn-id: svn://localhost/ardour2/branches/3.0@7334 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/midi_track.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libs/ardour/midi_track.cc b/libs/ardour/midi_track.cc index a104336c9e..3c43266219 100644 --- a/libs/ardour/midi_track.cc +++ b/libs/ardour/midi_track.cc @@ -348,6 +348,12 @@ MidiTrack::roll (nframes_t nframes, framepos_t start_frame, framepos_t end_frame BufferSet& bufs = _session.get_scratch_buffers (n_process_buffers()); MidiBuffer& mbuf (bufs.get_midi (0)); + /* we are a MIDI track, so we always start the chain with a single-channel diskstream */ + ChanCount c; + c.set_audio (0); + c.set_midi (1); + bufs.set_count (c); + diskstream->get_playback (mbuf, start_frame, end_frame); /* append immediate messages to the first MIDI buffer (thus sending it to the first output port) */ -- cgit v1.2.3