Modify architecture to run pipewire loop in second thread.

The pipewire loop now runs without interruption in a second thread and communicates with
the GTK thread via a channel in each direction, instead of checking for events once a second and using callbacks.

This allows changes to appear instantly in the view, instead of having to wait.
This commit is contained in:
Tom A. Wagner
2021-05-05 21:43:52 +02:00
parent 75aa0a30d0
commit 076fec7eb4
9 changed files with 292 additions and 346 deletions

View File

@@ -13,7 +13,7 @@ use gtk::{
glib::{self, clone},
prelude::*,
};
use pipewire::port::Direction;
use pipewire::spa::Direction;
use crate::controller::MediaType;