summaryrefslogtreecommitdiff
path: root/libs/ardour/automation_watch.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2017-08-29 17:16:03 +0200
committerRobin Gareus <robin@gareus.org>2017-08-29 17:25:23 +0200
commit6ab00534c0e8c372d759551e4f90a016918e71a9 (patch)
tree677df0b632cebf09cfc709f2095bdc1adb7359a0 /libs/ardour/automation_watch.cc
parent229c9584bfa7f84a246ccfc53779372d5d63cce4 (diff)
Set Automationwatch thread priority (needs to be higher than GUI)
This fixes an issue with sparse automation touch/write when the CPU is busy (stationary playhead, waveform rendering, or just high DSP load)
Diffstat (limited to 'libs/ardour/automation_watch.cc')
-rw-r--r--libs/ardour/automation_watch.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/libs/ardour/automation_watch.cc b/libs/ardour/automation_watch.cc
index a7a7a36eed..c949509d09 100644
--- a/libs/ardour/automation_watch.cc
+++ b/libs/ardour/automation_watch.cc
@@ -22,6 +22,7 @@
#include <glibmm/timer.h>
#include "pbd/compose.h"
+#include "pbd/pthread_utils.h"
#include "ardour/automation_control.h"
#include "ardour/automation_watch.h"
@@ -185,6 +186,7 @@ AutomationWatch::timer ()
void
AutomationWatch::thread ()
{
+ pbd_set_thread_priority (pthread_self(), SCHED_FIFO, -25);
while (_run_thread) {
Glib::usleep ((gulong) floor (Config->get_automation_interval_msecs() * 1000));
timer ();