- Update to version 0.3.63. OBS-URL: https://build.opensuse.org/request/show/1043200 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/pipewire?expand=0&rev=93
40 lines
1.5 KiB
Diff
40 lines
1.5 KiB
Diff
From f7c49bbdde5f9f09270ac391990264a501761420 Mon Sep 17 00:00:00 2001
|
|
From: Wim Taymans <wtaymans@redhat.com>
|
|
Date: Thu, 15 Dec 2022 13:12:47 +0100
|
|
Subject: [PATCH] pulse-server: add channel-map in echo-cancel module
|
|
|
|
---
|
|
.../module-protocol-pulse/modules/module-echo-cancel.c | 9 ++++++++-
|
|
1 file changed, 8 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/src/modules/module-protocol-pulse/modules/module-echo-cancel.c b/src/modules/module-protocol-pulse/modules/module-echo-cancel.c
|
|
index 47dfa75bb..72e0095b5 100644
|
|
--- a/src/modules/module-protocol-pulse/modules/module-echo-cancel.c
|
|
+++ b/src/modules/module-protocol-pulse/modules/module-echo-cancel.c
|
|
@@ -70,6 +70,7 @@ static int module_echo_cancel_load(struct module *module)
|
|
const char *str;
|
|
char *args;
|
|
size_t size;
|
|
+ uint32_t i;
|
|
|
|
if ((f = open_memstream(&args, &size)) == NULL)
|
|
return -errno;
|
|
@@ -85,7 +86,13 @@ static int module_echo_cancel_load(struct module *module)
|
|
fprintf(f, " audio.rate = %u", data->info.rate);
|
|
if (data->info.channels != 0) {
|
|
fprintf(f, " audio.channels = %u", data->info.channels);
|
|
- /* TODO: convert channel positions to string */
|
|
+ if (!(data->info.flags & SPA_AUDIO_FLAG_UNPOSITIONED)) {
|
|
+ fprintf(f, " audio.position = [ ");
|
|
+ for (i = 0; i < data->info.channels; i++)
|
|
+ fprintf(f, "%s%s", i == 0 ? "" : ",",
|
|
+ channel_id2name(data->info.position[i]));
|
|
+ fprintf(f, " ]");
|
|
+ }
|
|
}
|
|
fprintf(f, " source.props = {");
|
|
pw_properties_serialize_dict(f, &data->source_props->dict, 0);
|
|
--
|
|
2.39.0
|
|
|