From 2c0b92771a95693af7f14a70ddeddc5371e73996 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Wed, 3 Dec 2025 03:52:17 +0900 Subject: [PATCH] internal/pipewire: relocate constants This should make things easier to navigate, and possible to fully automatically generate the constants in the future. Signed-off-by: Ophestra --- internal/pipewire/pipewire.go | 354 --------------------- internal/pipewire/pipewire_test.go | 53 ---- internal/pipewire/pod.go | 120 -------- internal/pipewire/spa.go | 477 +++++++++++++++++++++++++++++ internal/pipewire/spa_test.go | 59 ++++ 5 files changed, 536 insertions(+), 527 deletions(-) create mode 100644 internal/pipewire/spa.go create mode 100644 internal/pipewire/spa_test.go diff --git a/internal/pipewire/pipewire.go b/internal/pipewire/pipewire.go index c3f57bf..2046f62 100644 --- a/internal/pipewire/pipewire.go +++ b/internal/pipewire/pipewire.go @@ -652,357 +652,3 @@ func closeReceivedFiles(fds ...int) { // Close frees the underlying buffer and closes the connection. func (ctx *Context) Close() error { ctx.free(); return ctx.conn.Close() } - -/* pipewire/device.h */ - -const ( - PW_TYPE_INTERFACE_Device = PW_TYPE_INFO_INTERFACE_BASE + "Device" - PW_DEVICE_PERM_MASK = PW_PERM_RWXM - PW_VERSION_DEVICE = 3 -) - -const ( - PW_DEVICE_CHANGE_MASK_PROPS = 1 << iota - PW_DEVICE_CHANGE_MASK_PARAMS - - PW_DEVICE_CHANGE_MASK_ALL = 1<