summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Raghavan <git@arunraghavan.net>2016-02-17 19:46:56 +0530
committerTanu Kaskinen <tanuk@iki.fi>2016-02-24 18:43:58 +0200
commitd777838fbb1a8e1f012e249bb1a0816d9141dd45 (patch)
tree68b5b559962a754f19e84048c28655539b5227b1
parentfab8a16b0f1fe55c0ac209a486f7a7546768867d (diff)
downloadpulseaudio-d777838fbb1a8e1f012e249bb1a0816d9141dd45.tar.gz
echo-cancel: Canceller may use different spec for playback and capture
The original intention was to configure low enough parameters to keep CPU consumption down. Prior to this change, we assumed that the EC backend would override the sink parameters based on the source parameters to achieve this goal, and with this change we remove that assumption by forcing the default parameters for the sink to be low enough.
-rw-r--r--src/modules/echo-cancel/module-echo-cancel.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/echo-cancel/module-echo-cancel.c b/src/modules/echo-cancel/module-echo-cancel.c
index 18fe5dce4..c3a6a1c9a 100644
--- a/src/modules/echo-cancel/module-echo-cancel.c
+++ b/src/modules/echo-cancel/module-echo-cancel.c
@@ -1690,7 +1690,9 @@ int pa__init(pa_module*m) {
pa_channel_map_init_auto(&source_map, source_ss.channels, PA_CHANNEL_MAP_DEFAULT);
sink_ss = sink_master->sample_spec;
- sink_map = sink_master->channel_map;
+ sink_ss.rate = DEFAULT_RATE;
+ sink_ss.channels = DEFAULT_CHANNELS;
+ pa_channel_map_init_auto(&sink_map, sink_ss.channels, PA_CHANNEL_MAP_DEFAULT);
u = pa_xnew0(struct userdata, 1);
if (!u) {