sample: Apply SPARC-specific condition on SPARC only

Improves correctness, unbreaks software volume in recent Android.
alsa-mixer: Prefer moving "Capture" before moving boosts

Some HD-audio codecs (at least ALC269VB and ALC283) become quite noisy on
high Mic Boost levels. So e g, if there is a "Mic Boost" and a "Capture"
control, both ranging from 0 dB to +30 dB, you get better quality if
"Mic Boost" is 0 dB and "Capture" is +30 dB, than the other way around.

By changing the order in the configuration files, this patch makes us prefer
leaving "Mic Boost" low and "Capture" high if the user selects a medium gain.

(This is based on limited experience, and there is no guarantee that there are
no sound cards that work the other way around, and therefore this patch could
potentially regress quality on those machines. Hopefully those are fewer, so
this is what we should default to.)

BugLink: https://bugs.launchpad.net/1085402
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
cli: Output prompt and welcome message only when requested by 'hello'

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
pacmd: Discriminate between interactive and non-interactive mode

interactive sessions are initiated with a hello message in order to
receive a welcome message from the PA daemon and a command prompt

interactive sessions have a terminal connected to stdin

non-interactive sessions execute commands given on the command line
or received via stdin; non-interactive sessions have neither welcome
message nor command prompt

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
cli: Use pa_xnew0 to save some 0 inits

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
i18n: Update zh_TW translation

https://bugs.freedesktop.org/show_bug.cgi?id=56454
thread-mq: Support a mainloop as thread/consumer

This is needed by the tunnel module rewrite, which runs pa_mainloop in
the IO thread instead of pa_rtpoll.

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
doc: Update LICENSE to reflect optional libpulse dep on libdbus
alsa: Trivial whitespace deletion
sink-input: Don't assert when removing non-existent volume factor

This makes it easier for users of this API to add/updated a volume
factor by doing a _remove_volume_factor() followed by an
add_volume_factor(), rather than having to either remember whether this
is the first set operation or have an API to query whether a factor has
already been set.
pacat: Added support for recording from one specific sink input

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=66326
bash-completion: Fix device completion for pacat

The Bash shell completion for pacat --device combines the name of the
last sink and the name of the first source. This patch fixes that by
adding a whitespace separator in the list of devices.

Buglink: https://bugs.freedesktop.org/show_bug.cgi?id=68106
client-conf: refactor cookie loaders

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
tunnel-sink-new: add a rewrite of module-tunnel using libpulse

The old tunnel module duplicates functionality that is in libpulse,
due to implementing the native protocol, and the protocol code in
the old tunnel module tends to get broken every now and then, because
people forget to update the tunnel module protocol implementation
when changing the native protocol. module-tunnel-sink-new avoids this
problem by using libpulse to communicate with the remote server.

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
source-output: Get the correct source for "direct_on_input" streams

If a capture stream captures from a single sink input (so the capture
stream is a so called "direct on input" stream), then it needs to
connect to the monitor source of the sink to which the sink input is
connected. Previously the correct source was not figured out
automatically, causing the capture stream creation to fail.
sink, source: Reduce indentation level in *_update_rate()
sink, source: Don't care about default and alternate rate in passthrough mode

In passthrough mode the device rate is set to match the stream rate,
and the default and alternate rates are ignored.
sink, source: Fix default and alternate rate assertions
sink, source: Small readability improvement