udev-detect, alsa-card: Adopt avoid resampling option from daemon.conf

Previously, the "avoid-resampling" option of daemon.conf is to make the
daemon try to use the stream sample rate if possible for all sinks or
sources.

This patch applies this option to module-udev-detect and module-alsa-card
as a module argument in order to override the default value of daemon.conf.

As a result, user can use this argument for more fine-grained control.
e.g.) set it false in daemon.conf and set it true for module-udev-detect
or a particular module-alsa-card in default.pa.(or vice versa)

To set it, use "avoid_resampling=true or false" as the module argument.

Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
This commit is contained in:
Sangchul Lee 2018-05-25 01:29:53 +09:00 committed by Arun Raghavan
parent 3b2a5bdc10
commit ef094638f5
8 changed files with 64 additions and 8 deletions

View file

@ -68,6 +68,7 @@ PA_MODULE_USAGE(
"profile_set=<profile set configuration file> "
"paths_dir=<directory containing the path configuration files> "
"use_ucm=<load use case manager> "
"avoid_resampling=<use stream original sample rate if possible?> "
);
static const char* const valid_modargs[] = {
@ -95,6 +96,7 @@ static const char* const valid_modargs[] = {
"profile_set",
"paths_dir",
"use_ucm",
"avoid_resampling",
NULL
};