AsyncMIDIPort (std::string const &, PortFlags);
~AsyncMIDIPort ();
- /* called from an RT context */
+ bool flush_at_cycle_start () const { return _flush_at_cycle_start; }
+ void set_flush_at_cycle_start (bool en) { _flush_at_cycle_start = en; }
+ /* called from an RT context */
void cycle_start (pframes_t nframes);
void cycle_end (pframes_t nframes);
/* called from non-RT context */
- void parse (framecnt_t timestamp);
+ void parse (samplecnt_t timestamp);
int write (const MIDI::byte *msg, size_t msglen, MIDI::timestamp_t timestamp);
int read (MIDI::byte *buf, size_t bufsize);
/* waits for output to be cleared */
/* Not selectable; use ios() */
int selectable() const { return -1; }
- void set_timer (boost::function<framecnt_t (void)>&);
+ void set_timer (boost::function<samplecnt_t (void)>&);
static void set_process_thread (pthread_t);
static pthread_t get_process_thread () { return _process_thread; }
private:
bool _currently_in_cycle;
MIDI::timestamp_t _last_write_timestamp;
+ bool _flush_at_cycle_start;
bool have_timer;
- boost::function<framecnt_t (void)> timer;
- RingBuffer< Evoral::Event<double> > output_fifo;
+ boost::function<samplecnt_t (void)> timer;
+ PBD::RingBuffer< Evoral::Event<double> > output_fifo;
EventRingBuffer<MIDI::timestamp_t> input_fifo;
Glib::Threads::Mutex output_fifo_lock;
CrossThreadChannel _xthread;