mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-06-21 03:13:56 +02:00
Run events async and centralized for group hosts
At a 30 fps rate with a limit on the number of window messages per frame. This is somehow needed for Melda plugins, as they otherwise dispatch tiemr messages indefinitely after opening a second editor with seemingly no way around it. With this and some refactoring #15 should be almost done.
This commit is contained in:
@@ -183,6 +183,13 @@ class GroupBridge {
|
||||
*/
|
||||
void accept_requests();
|
||||
|
||||
/**
|
||||
* Handle both Win32 messages and X11 events on a timer within the IO
|
||||
* context. This is a centralized replacement for the event handling in
|
||||
* `Vst2Bridge::handle_dispatch_single` for plugin groups.
|
||||
*/
|
||||
void async_handle_events();
|
||||
|
||||
/**
|
||||
* Continuously read from a pipe and write the output to the log file. Used
|
||||
* with the IO streams captured by `stdout_redirect` and `stderr_redirect`.
|
||||
@@ -268,6 +275,14 @@ class GroupBridge {
|
||||
*/
|
||||
std::mutex active_plugins_mutex;
|
||||
|
||||
/**
|
||||
* A timer used to repeatedly handle the Win32 message loop and the X11
|
||||
* events.
|
||||
*
|
||||
8 @see async_handle_events
|
||||
*/
|
||||
boost::asio::steady_timer events_timer;
|
||||
|
||||
/**
|
||||
* A timer to defer shutting down the process, allowing for fast plugin
|
||||
* scanning without having to start a new group host process for each
|
||||
|
||||
Reference in New Issue
Block a user