diff options
author | Jesse Chappell <jesse@essej.net> | 2006-01-06 04:59:17 +0000 |
---|---|---|
committer | Jesse Chappell <jesse@essej.net> | 2006-01-06 04:59:17 +0000 |
commit | bd21c474e547d49338ea0efd452895de1e147cd5 (patch) | |
tree | 2993bc781777530afc180313c9f69cc898f851e0 /libs/ardour/session_feedback.cc | |
parent | 18844bac7aa0747453ed4d04c4a462f2044a43bb (diff) |
committed RWlock fixes to libardour. added hw monitoring fixes from nick_m. minor alsa midi fix and update rate settings.
git-svn-id: svn://localhost/trunk/ardour2@244 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/session_feedback.cc')
-rw-r--r-- | libs/ardour/session_feedback.cc | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libs/ardour/session_feedback.cc b/libs/ardour/session_feedback.cc index c2198aa55d..2e6d0cd80b 100644 --- a/libs/ardour/session_feedback.cc +++ b/libs/ardour/session_feedback.cc @@ -124,7 +124,7 @@ Session::feedback_thread_work () if (active_feedback) { /* XXX use Config->feedback_interval_usecs()*/; - timeout = 250; + timeout = max (5, (int) Config->get_midi_feedback_interval_ms()); } else { timeout = -1; } @@ -162,7 +162,7 @@ Session::feedback_thread_work () switch ((FeedbackRequest::Type) req) { case FeedbackRequest::Start: - timeout = 250; + timeout = max (5, (int) Config->get_midi_feedback_interval_ms()); active_feedback++; break; @@ -193,7 +193,7 @@ Session::feedback_thread_work () } } - if (!active_feedback) { + if (!active_feedback || transport_stopped()) { continue; } @@ -224,7 +224,7 @@ Session::feedback_generic_midi_function () MIDI::byte* end = buf; { - LockMonitor lm (route_lock, __LINE__, __FILE__); + RWLockMonitor lm (route_lock, false, __LINE__, __FILE__); for (RouteList::iterator i = routes.begin(); i != routes.end(); ++i) { end = (*i)->write_midi_feedback (end, bsize); @@ -236,10 +236,11 @@ Session::feedback_generic_midi_function () return 0; } - // cerr << "MIDI feedback: write " << (int32_t) (end - buf) << " of " << buf << " to midi port\n"; - deliver_midi (_midi_port, buf, (int32_t) (end - buf)); + //cerr << "MIDI feedback: wrote " << (int32_t) (end - buf) << " to midi port\n"; + + return 0; } |