]> code.delx.au - pulseaudio/log
pulseaudio
10 years agobluetooth: Implement org.bluez.MediaEndpoint1.SelectConfiguration()
João Paulo Rechi Vita [Tue, 24 Sep 2013 22:45:25 +0000 (19:45 -0300)]
bluetooth: Implement org.bluez.MediaEndpoint1.SelectConfiguration()

10 years agobluetooth: Implement org.bluez.MediaEndpoint1.SetConfiguration()
João Paulo Rechi Vita [Tue, 24 Sep 2013 22:45:24 +0000 (19:45 -0300)]
bluetooth: Implement org.bluez.MediaEndpoint1.SetConfiguration()

10 years agobluetooth: Register MediaEndpoint1 objects with D-Bus
João Paulo Rechi Vita [Tue, 24 Sep 2013 22:45:23 +0000 (19:45 -0300)]
bluetooth: Register MediaEndpoint1 objects with D-Bus

10 years agobluetooth: Create pa_bluetooth_transport for BlueZ 5 support
João Paulo Rechi Vita [Tue, 24 Sep 2013 22:45:22 +0000 (19:45 -0300)]
bluetooth: Create pa_bluetooth_transport for BlueZ 5 support

Create the pa_bluetooth_transport structure to store information about
the bluetooth transport and utility functions to manipulate this
structure. The acquire() and release() operations are function pointers
in the pa_bluetooth_transport structure to make possible for different
transport backends to provide different implementations of these
operations. Thre is also a userdata field for the transport backend
provide data for the acquire/release functions.

This commit also creates a new function
pa_bluetooth_device_any_transport_connected() to check if there is any
audio connection between the host and a remote device.

10 years agobluetooth: Remove all devices and adapters when org.bluez goes away
João Paulo Rechi Vita [Tue, 24 Sep 2013 22:45:21 +0000 (19:45 -0300)]
bluetooth: Remove all devices and adapters when org.bluez goes away

10 years agobluetooth: Create pa_bluetooth_device for BlueZ 5 support
João Paulo Rechi Vita [Wed, 18 Sep 2013 21:16:58 +0000 (16:16 -0500)]
bluetooth: Create pa_bluetooth_device for BlueZ 5 support

Create a structure pa_bluetooth_device to store information about the
bluetooth device and utility functions to manipulate this structure.

10 years agobluetooth: Create pa_bluetooth_adapter for BlueZ 5 support
João Paulo Rechi Vita [Wed, 18 Sep 2013 21:16:57 +0000 (16:16 -0500)]
bluetooth: Create pa_bluetooth_adapter for BlueZ 5 support

10 years agobluetooth: Create infrastrucure for bluetooth hooks
João Paulo Rechi Vita [Wed, 18 Sep 2013 21:16:56 +0000 (16:16 -0500)]
bluetooth: Create infrastrucure for bluetooth hooks

Create a pa_bluetooth_hook enum type and API to get pa_hooks from the
opaque pa_bluetooth_discovery struct.

10 years agobluetooth: Track org.bluez for BlueZ 5
João Paulo Rechi Vita [Wed, 18 Sep 2013 21:16:55 +0000 (16:16 -0500)]
bluetooth: Track org.bluez for BlueZ 5

10 years agobluetooth: Create pa_bluetooth_discovery for BlueZ 5
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:54:00 +0000 (01:54 -0300)]
bluetooth: Create pa_bluetooth_discovery for BlueZ 5

pa_bluetooth_discovery is the struct that holds information about known
Bluetooth audio devices and other information about the Bluetooth stack.

This commit also creates bluez5-util.[ch], which will hold a lot of
utility functions to help with the BlueZ 5 support.

10 years agobluetooth: Create stub for module-bluez5-discover
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:59 +0000 (01:53 -0300)]
bluetooth: Create stub for module-bluez5-discover

10 years agobuild: Add support for enabling/disabling BlueZ 5 support
João Paulo Rechi Vita [Fri, 16 Aug 2013 12:40:54 +0000 (09:40 -0300)]
build: Add support for enabling/disabling BlueZ 5 support

10 years agobuild: Make the build of bluetooth modules BlueZ 4 specific
João Paulo Rechi Vita [Fri, 16 Aug 2013 12:31:45 +0000 (09:31 -0300)]
build: Make the build of bluetooth modules BlueZ 4 specific

10 years agobluetooth: Remove module-bluetooth-proximity
João Paulo Rechi Vita [Fri, 16 Aug 2013 12:30:41 +0000 (09:30 -0300)]
bluetooth: Remove module-bluetooth-proximity

module-bluetooth-proximity has not worked for quite a while, since it
uses pre-BlueZ4 APIs. Nobody complained since then, which is a good
indication that it doesn't have much users. Even the original commit
message refers to it more as a toy than as something of great use: "add
new fun module that automatically mutes your audio devices when you
leave with your bluetooth phone, and unmutes when you come back"

Removing it we completely remove the dependency on libbluetooth.

10 years agobluetooth: Prefix BlueZ 4 card profiles enum with PA_BLUEZ4_
João Paulo Rechi Vita [Thu, 15 Aug 2013 19:17:26 +0000 (16:17 -0300)]
bluetooth: Prefix BlueZ 4 card profiles enum with PA_BLUEZ4_

Also typedef the enum as pa_bluez4_profile_t.

10 years agobluetooth: Register BlueZ 4 endpoints in a separate object path
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:55 +0000 (01:53 -0300)]
bluetooth: Register BlueZ 4 endpoints in a separate object path

We need diferent object paths for BlueZ 4 and BlueZ 5 endpoints to avoid
crashing the daemon in the case both modules are loaded in parallel.

10 years agobluetooth: Name BlueZ 4 symbols accordingly
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:54 +0000 (01:53 -0300)]
bluetooth: Name BlueZ 4 symbols accordingly

We need diferent symbol prefixing for the current BlueZ 4 support and
the new BlueZ 5 support which is about to enter the codebase, to avoid
symbol clashing and crashing the daemon in the case both modules are
loaded at the same time.

This commit replaces all pa_bluetooth_ and pa_bt_ (for consistency)
prefixes with pa_bluez4_, for both lower-case and upper-case, what was
done with the following sed commands:

 $ sed -i s/pa_bluetooth_/pa_bluez4_/g src/modules/bluetooth/*bluez4*
 $ sed -i s/PA_BLUETOOTH_/PA_BLUEZ4_/g src/modules/bluetooth/*bluez4*
 $ sed -i s/pa_bt_/pa_bluez4_/g src/modules/bluetooth/*bluez4*
 $ sed -i s/PA_BT_/PA_BLUEZ4_/g src/modules/bluetooth/*bluez4*

10 years agobluetooth: Rename shared struct to make it BlueZ 4 specific
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:53 +0000 (01:53 -0300)]
bluetooth: Rename shared struct to make it BlueZ 4 specific

10 years agobluetooth: Rename bluetooth modules to BlueZ 4
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:52 +0000 (01:53 -0300)]
bluetooth: Rename bluetooth modules to BlueZ 4

10 years agobluetooth: Update modules description and copyright
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:51 +0000 (01:53 -0300)]
bluetooth: Update modules description and copyright

The current set of bluetooth modules only support up to BlueZ 4. Since
the BlueZ API when through a big change with the release of BlueZ 5 the
modules will be forked into a new set for BlueZ 5.

This commit also fixes the spelling of Bluetooth (it's a trademark which
should always be spelled with capital B) and the spelling of my name,
and also update the copyright note dates throughout the Bluetooth
modules.

10 years agoRevert "bluetooth: Detect BlueZ 5"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:50 +0000 (01:53 -0300)]
Revert "bluetooth: Detect BlueZ 5"

This reverts commit 2247b187393ef68879162faee8b422da9f5e556f.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Parse the tree returned by ObjectManager"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:49 +0000 (01:53 -0300)]
Revert "bluetooth: Parse the tree returned by ObjectManager"

This reverts commit c4bd51a34547ed0991ff3c7219c2d5de49669ca8.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Fix error checking style"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:48 +0000 (01:53 -0300)]
Revert "bluetooth: Fix error checking style"

This reverts commit d9ed42c40f744b273c8d466e95dd4a06e41364b9.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: BlueZ 5 interface rename to org.bluez.MediaEndpoint1"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:47 +0000 (01:53 -0300)]
Revert "bluetooth: BlueZ 5 interface rename to org.bluez.MediaEndpoint1"

This reverts commit d22ea7ff7630bef83a3bf8c26cc56c196dec33a1.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: BlueZ 5 interface rename to org.bluez.Media1"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:46 +0000 (01:53 -0300)]
Revert "bluetooth: BlueZ 5 interface rename to org.bluez.Media1"

This reverts commit 61e8fd8854308cb2d41e6313f25ae7131c912ea8.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: BlueZ 5 interface rename to org.bluez.MediaTransport1"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:45 +0000 (01:53 -0300)]
Revert "bluetooth: BlueZ 5 interface rename to org.bluez.MediaTransport1"

This reverts commit cfb96b2530690df113e1aceb5b82fc166f9d2cfd.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Support ObjectManager interface add/remove"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:44 +0000 (01:53 -0300)]
Revert "bluetooth: Support ObjectManager interface add/remove"

This reverts commit 114edb0696ce979ad10f5616067afda1b76ae4e2.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Support Properties.PropertiesChanged signal"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:43 +0000 (01:53 -0300)]
Revert "bluetooth: Support Properties.PropertiesChanged signal"

This reverts commit 235611a7d13ab251689f5b480183d7f39e043a2e.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Parse media transport's properties"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:42 +0000 (01:53 -0300)]
Revert "bluetooth: Parse media transport's properties"

This reverts commit 2f79fb580ad583b2492b567d32630e7e03883855.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Support media transport's State property"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:41 +0000 (01:53 -0300)]
Revert "bluetooth: Support media transport's State property"

This reverts commit 6fdf2b05b8867d4597c497243b469ecd0d8c2426.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Update to new BlueZ 5 transport acquire/release API"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:40 +0000 (01:53 -0300)]
Revert "bluetooth: Update to new BlueZ 5 transport acquire/release API"

This reverts commit 9615def4b96f0bab365ddc03f6c003f382a54752.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agoRevert "bluetooth: Support transport auto-release"
João Paulo Rechi Vita [Tue, 13 Aug 2013 04:53:39 +0000 (01:53 -0300)]
Revert "bluetooth: Support transport auto-release"

This reverts commit 0e4c16e120f95b122c7139deb046192927d1b6c7.

This is part of the reversion of BlueZ 5 support so it can be added back
in a separate set of modules. This makes the code easier to maintain and
decrease PulseAudio's binary size.

10 years agobuild-sys: Support building pulseaudio as a submodule
Anton Lundin [Wed, 18 Sep 2013 14:20:42 +0000 (16:20 +0200)]
build-sys: Support building pulseaudio as a submodule

When pulseaudio is a submodule, .git is a file.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
10 years agomutex: Fix compiler warning when priority inheritance is not supported
Arun Raghavan [Sat, 28 Sep 2013 03:42:01 +0000 (09:12 +0530)]
mutex: Fix compiler warning when priority inheritance is not supported

'r' is unused in the case where prioritiy inheritance is not detected at
configure time.

10 years agoresampler: Revert to auto if the rates are equal and copy is chosen
poljar (Damir Jelić) [Wed, 11 Sep 2013 20:47:24 +0000 (22:47 +0200)]
resampler: Revert to auto if the rates are equal and copy is chosen

This patch fixes a small mistake where we actually log that we are
reverting to the auto resampler if we can't use the 'copy' resampler but
never do the revert.

This would lead to a crash if the user chooses the 'copy' resampler and
then tries to play something that needs to be resampled.

10 years agoalsa: Turn one assertion into two
David Henningsson [Mon, 23 Sep 2013 07:53:41 +0000 (09:53 +0200)]
alsa: Turn one assertion into two

According to coding style, one should have one assertion per line
and not combine assertions.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
10 years agosink: Increase max sink inputs per sink
Arun Raghavan [Fri, 20 Sep 2013 03:42:51 +0000 (09:12 +0530)]
sink: Increase max sink inputs per sink

We're hitting the 32 sink-input limit quite often with increasing use of
PA by web browsers, so let's increase this limit.

10 years ago.gitignore: Add .dirstamp
Tanu Kaskinen [Thu, 19 Sep 2013 12:53:36 +0000 (15:53 +0300)]
.gitignore: Add .dirstamp

10 years agomodule-tunnel: Fixup broken build
David Henningsson [Wed, 18 Sep 2013 13:07:37 +0000 (15:07 +0200)]
module-tunnel: Fixup broken build

A recent feature addition added a dependency on X11, but this
dependency was not specified in Makefile.am, leading to linker
errors.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
10 years agolog: Add missing header
Arun Raghavan [Tue, 17 Sep 2013 16:24:09 +0000 (21:54 +0530)]
log: Add missing header

sys/stat.h is required for permisison flags such as S_IRUSR.

10 years agobuild-sys: Fix warning in use-case.h configure check
Arun Raghavan [Tue, 17 Sep 2013 13:43:44 +0000 (19:13 +0530)]
build-sys: Fix warning in use-case.h configure check

AC_CHECK_HEADER uses cpp for header checks, so in order for the check to use
the right flags, we need to override CPPFLAGS and not CFLAGS.

10 years agobuild-sys: Update ax_pthread macro
poljar (Damir Jelić) [Mon, 16 Sep 2013 00:00:36 +0000 (02:00 +0200)]
build-sys: Update ax_pthread macro

This patch updates the ax_pthread autoconf macro to the latest version
shipped with autoconf-archive: 2013.06.09.13

This also silences multiple warnings on autoconf 2.68+:
    configure.ac:471: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body

10 years agobuild-sys: Silence warning about missing AC_LANG_SOURCE call in acx_libwrap.m4
poljar (Damir Jelić) [Mon, 16 Sep 2013 00:00:35 +0000 (02:00 +0200)]
build-sys: Silence warning about missing AC_LANG_SOURCE call in acx_libwrap.m4

This updates the acx_libwrap.m4 macro for autoconf 2.68 and fixes
warnings like:
    configure.ac:471: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body

10 years agobuild-sys: Silence warning about missing AC_LANG_SOURCE call in configure.ac
poljar (Damir Jelić) [Mon, 16 Sep 2013 00:00:34 +0000 (02:00 +0200)]
build-sys: Silence warning about missing AC_LANG_SOURCE call in configure.ac

This silences multiple warnings like this on autoconf 2.68+:
    configure.ac:471: warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body

10 years agobuild-sys: Enable subdir-objects option
poljar (Damir Jelić) [Mon, 16 Sep 2013 00:00:33 +0000 (02:00 +0200)]
build-sys: Enable subdir-objects option

Automake 1.14 throws a warning when source files are in a sub directory
and the 'subdir-objecs' option is not enabled.

News: https://lists.gnu.org/archive/html/automake/2013-06/msg00040.html

10 years agoalsa-ucm: Make combination port names deterministic
Arun Raghavan [Wed, 21 Aug 2013 09:28:06 +0000 (14:58 +0530)]
alsa-ucm: Make combination port names deterministic

At the moment, port names combined from multiple devices are generated
based on the order that the devices are specified in config. This makes
programmatic use of thsee ports a bit painful, so let's make them be
combined in alphabetical order.

10 years agoalsa-ucm: Use playback/capture rate specification from UCM
Arun Raghavan [Wed, 7 Aug 2013 17:26:58 +0000 (22:56 +0530)]
alsa-ucm: Use playback/capture rate specification from UCM

Add new PlaybackRate/CaptureRate values for UCM that can be used to
specify custom rates for devices. This value can either be set on the
verb, which makes it apply to all devices, or on the device to override
the verb setting.

10 years agoalsa: Allow sample spec override in mappings
Arun Raghavan [Wed, 7 Aug 2013 12:56:26 +0000 (18:26 +0530)]
alsa: Allow sample spec override in mappings

This allows mappings to override some or all of the sample_spec used to
open the ALSA device. The intention, to start with, is to use this for
devices in UCM that need to be opened at a specific rate (like modem
devices). This can be extended to allow overrides in profile-sets as
well.

10 years agohashmap: Add the ability to free keys
Arun Raghavan [Sat, 14 Sep 2013 06:20:10 +0000 (11:50 +0530)]
hashmap: Add the ability to free keys

Since the hashmap stores a pointer to the key provided at pa_hashmap_put()
time, it make sense to allow the hashmap to be given ownership of the key and
have it free it at pa_hashmap_remove/free time.

To do this cleanly, we now provide the key and value free functions at hashmap
creation time with a pa_hashmap_new_full. With this, we do away with the free
function that was provided at remove/free time for freeing the value.

10 years agoi18n: remove unneeded files from POTFILES.in
Piotr Drąg [Fri, 13 Sep 2013 18:04:50 +0000 (20:04 +0200)]
i18n: remove unneeded files from POTFILES.in

10 years agoi18n: add missing files to POTFILES.in
Piotr Drąg [Fri, 13 Sep 2013 17:56:57 +0000 (19:56 +0200)]
i18n: add missing files to POTFILES.in

10 years agoi18n: sort POTFILES.in alphabetically
Piotr Drąg [Fri, 13 Sep 2013 17:55:14 +0000 (19:55 +0200)]
i18n: sort POTFILES.in alphabetically

10 years agomodule-tunnel: automatically find the PulseAudio server
Pierre Ossman [Thu, 11 Jul 2013 11:57:41 +0000 (13:57 +0200)]
module-tunnel: automatically find the PulseAudio server

Make the PulseAudio tunnel behave the same way as a client
when it comes to figuring out how to connect to the current
PulseAudio daemon. This can be useful if you start a second
PulseAudio instance for e.g. network access.

10 years agosuspend-on-idle: Allow disabling suspending for specific devices
Tanu Kaskinen [Thu, 29 Aug 2013 14:36:53 +0000 (17:36 +0300)]
suspend-on-idle: Allow disabling suspending for specific devices

Sometimes it would be nice to disable module-suspend-on-idle for
specific devices. For me the use case is to keep a HDMI sink running
all the time to avoid loss of audio when starting to play a stream to
the device (the HDMI receiver eats a bit from the beginning of the
stream when the device is opened). This is arguably a hacky solution
to the problem, but on the other hand, I think it's very sensible to
interpret negative timeout in the module-suspend-on-idle.timeout
property as disabling the suspending altogher. This is also how the
exit-idle-time configuration option behaves (negative value disables
automatic exiting).

I moved the property parsing from the timer restart function to the
function that creates the device_info objects, because if the timeout
is negative, we don't need to create the device_info object at all.

10 years agotunnel-source-new: counterpart to module-tunnel-sink-new
Alexander Couzens [Thu, 12 Sep 2013 12:01:51 +0000 (14:01 +0200)]
tunnel-source-new: counterpart to module-tunnel-sink-new

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-source-new avoids this
problem by using libpulse to communicate with the remote server.

10 years agoi18n: Japanese translation update
victory [Tue, 10 Sep 2013 06:10:03 +0000 (09:10 +0300)]
i18n: Japanese translation update

10 years agoresampler: Never return zero for max block size
Tanu Kaskinen [Wed, 28 Aug 2013 11:11:54 +0000 (14:11 +0300)]
resampler: Never return zero for max block size

With very low input sample rates the memory pool max block size may
not be big enough, in which case we should return the size of one
frame. Returning zero caused crashing.

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=68616
10 years agocard-restore: Watch for profiles added after card creation.
poljar (Damir Jelić) [Thu, 25 Jul 2013 14:39:01 +0000 (16:39 +0200)]
card-restore: Watch for profiles added after card creation.

This patch adds the ability to restore profiles if they are added after
card creation.

Adding profiles after card creation mainly happens for bluetooth cards.

Buglink: https://bugs.freedesktop.org/show_bug.cgi?id=65349
10 years agocontext: add pa_context_load_cookie_from_file()
Alexander Couzens [Tue, 27 Aug 2013 01:18:35 +0000 (03:18 +0200)]
context: add pa_context_load_cookie_from_file()

There is no function to load the authentication cookie for a context.
You can only set environment variables. This patch adds
pa_context_load_cookie_from_file().

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
10 years agosink, source: Fix error reporting style for rate updates
Tanu Kaskinen [Fri, 23 Aug 2013 10:58:55 +0000 (13:58 +0300)]
sink, source: Fix error reporting style for rate updates

10 years agosource: When updating a monitor source's rate, update the sink rate too
Tanu Kaskinen [Fri, 9 Aug 2013 06:39:49 +0000 (09:39 +0300)]
source: When updating a monitor source's rate, update the sink rate too

If the sink rate is not updated, then the monitor source will appear
to have a different rate than the sink, but in reality there's never
any resampling done when moving data from the sink to the monitor
source, so it's a lie that the monitor source has a different rate.
The result of lying is that clients that capture from the monitor
source will have streams that run too fast or slow.

10 years agosource: Fix monitor source rate changing
Tanu Kaskinen [Fri, 9 Aug 2013 04:45:26 +0000 (07:45 +0300)]
source: Fix monitor source rate changing

When a sink changes its sample rate, also the monitor source rate
needs to be changed. In order to determine whether a source supports
rate changing, the code checks if the update_rate() callback is set,
but monitor sources don't have that callback set, so the old code
always failed to change the monitor source rate.

This patch fixes the monitor source rate changing by handling monitor
sources as a special case in pa_source_update_rate(): if the source is
a monitor source, then the update_rate() callback is not required.

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=66424
10 years agoresampler: Add a choose_auto_resampler function
poljar (Damir Jelić) [Wed, 7 Aug 2013 17:55:44 +0000 (19:55 +0200)]
resampler: Add a choose_auto_resampler function

This function returns our preferred resampler if the user choose the
auto (or if he has chosen an unsupported) resampler.

10 years agoresampler: Get rid of redundant implementation specific structs
poljar (Damir Jelić) [Wed, 7 Aug 2013 17:37:55 +0000 (19:37 +0200)]
resampler: Get rid of redundant implementation specific structs

This patch removes implementation specific structs that contain a single
member.

10 years agoresampler: Add assert to set_input/output_rate
poljar (Damir Jelić) [Wed, 10 Jul 2013 11:10:04 +0000 (13:10 +0200)]
resampler: Add assert to set_input/output_rate

This adds asserts to check if the implementation has an update rate
function defined for the unlikely event that some implementation forgets
to assign a update rate function we can simply bail.

It is expected from the resampling implementations to have such a
function even if the state of the resampler is completely reset.

10 years agoresampler: Introduce a implementation specific struct
poljar (Damir Jelić) [Mon, 24 Jun 2013 11:36:49 +0000 (13:36 +0200)]
resampler: Introduce a implementation specific struct

This struct holds all the implementation specific data in one place.

10 years agoResampler: Don't use the peaks resampler for upsampling
poljar (Damir Jelić) [Fri, 28 Jun 2013 16:55:04 +0000 (18:55 +0200)]
Resampler: Don't use the peaks resampler for upsampling

This patch fixes this assertion:
    Assertion 'r->i_ss.rate >= r->o_ss.rate' failed at ../../src/pulsecore/resampler.c:1744, function peaks_init(). Aborting.

10 years agoresampler: Add a function for comparing sample format precision
poljar (Damir Jelić) [Fri, 28 Jun 2013 15:58:22 +0000 (17:58 +0200)]
resampler: Add a function for comparing sample format precision

10 years agoresampler: choose_work_format use switch instead of if/else
poljar (Damir Jelić) [Thu, 11 Jul 2013 17:28:29 +0000 (19:28 +0200)]
resampler: choose_work_format use switch instead of if/else

This way the function for choosing the work format should
be more readable and easier to expand in the future.

10 years agoresampler: Move the work format finding logic into a separate function
poljar (Damir Jelić) [Wed, 26 Jun 2013 14:31:49 +0000 (16:31 +0200)]
resampler: Move the work format finding logic into a separate function

10 years agoresampler: fix_method use switch instead of if/else
poljar (Damir Jelić) [Wed, 26 Jun 2013 14:09:08 +0000 (16:09 +0200)]
resampler: fix_method use switch instead of if/else

This way the fix method function should be more readable and easier to
expand in the future.

10 years agoresampler: Move the fix method logic into a separate function
poljar (Damir Jelić) [Wed, 26 Jun 2013 11:51:55 +0000 (13:51 +0200)]
resampler: Move the fix method logic into a separate function

10 years agoresampler: Make resampler struct implementation agnostic
poljar (Damir Jelić) [Tue, 18 Jun 2013 12:22:26 +0000 (14:22 +0200)]
resampler: Make resampler struct implementation agnostic

The pa_resampler struct contains many implementation specific
structures. These create overhead and don't belong there anyways.

This patch moves the implementation specific structures out of the
pa_resampler structure.

10 years agosink, source: Return early from pa_*_update_rate(), if there's no need to do anything
Tanu Kaskinen [Fri, 9 Aug 2013 06:38:02 +0000 (09:38 +0300)]
sink, source: Return early from pa_*_update_rate(), if there's no need to do anything

10 years agosink, source: Small readability improvement
Tanu Kaskinen [Fri, 9 Aug 2013 05:56:23 +0000 (08:56 +0300)]
sink, source: Small readability improvement

10 years agosink, source: Fix default and alternate rate assertions
Tanu Kaskinen [Fri, 9 Aug 2013 05:55:52 +0000 (08:55 +0300)]
sink, source: Fix default and alternate rate assertions

10 years agosink, source: Don't care about default and alternate rate in passthrough mode
Tanu Kaskinen [Fri, 9 Aug 2013 05:51:12 +0000 (08:51 +0300)]
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.

10 years agosink, source: Reduce indentation level in *_update_rate()
Tanu Kaskinen [Fri, 9 Aug 2013 04:42:07 +0000 (07:42 +0300)]
sink, source: Reduce indentation level in *_update_rate()

10 years agosource-output: Get the correct source for "direct_on_input" streams
Tanu Kaskinen [Wed, 14 Aug 2013 13:54:28 +0000 (16:54 +0300)]
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.

10 years agotunnel-sink-new: add a rewrite of module-tunnel using libpulse
Alexander Couzens [Wed, 21 Aug 2013 11:58:19 +0000 (13:58 +0200)]
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>
10 years agoclient-conf: refactor cookie loaders
Alexander Couzens [Wed, 21 Aug 2013 11:48:12 +0000 (13:48 +0200)]
client-conf: refactor cookie loaders

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
10 years agobash-completion: Fix device completion for pacat
poljar (Damir Jelić) [Wed, 14 Aug 2013 14:09:06 +0000 (16:09 +0200)]
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
10 years agopacat: Added support for recording from one specific sink input
Magnus Ekhall [Sun, 11 Aug 2013 19:21:41 +0000 (21:21 +0200)]
pacat: Added support for recording from one specific sink input

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=66326
10 years agosink-input: Don't assert when removing non-existent volume factor
Arun Raghavan [Sat, 3 Aug 2013 06:09:17 +0000 (11:39 +0530)]
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.

10 years agoalsa: Trivial whitespace deletion
Arun Raghavan [Wed, 7 Aug 2013 13:00:44 +0000 (18:30 +0530)]
alsa: Trivial whitespace deletion

10 years agodoc: Update LICENSE to reflect optional libpulse dep on libdbus
Arun Raghavan [Tue, 25 Jun 2013 03:50:03 +0000 (09:20 +0530)]
doc: Update LICENSE to reflect optional libpulse dep on libdbus

10 years agothread-mq: Support a mainloop as thread/consumer
Alexander Couzens [Tue, 6 Aug 2013 03:29:45 +0000 (05:29 +0200)]
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>
10 years agoi18n: Update zh_TW translation
Cheng-Chia Tseng [Tue, 6 Aug 2013 03:47:39 +0000 (09:17 +0530)]
i18n: Update zh_TW translation

https://bugs.freedesktop.org/show_bug.cgi?id=56454

10 years agocli: Use pa_xnew0 to save some 0 inits
Peter Meerwald [Mon, 29 Jul 2013 20:13:42 +0000 (22:13 +0200)]
cli: Use pa_xnew0 to save some 0 inits

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
10 years agopacmd: Discriminate between interactive and non-interactive mode
Peter Meerwald [Mon, 29 Jul 2013 20:13:41 +0000 (22:13 +0200)]
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>
10 years agocli: Output prompt and welcome message only when requested by 'hello'
Peter Meerwald [Mon, 29 Jul 2013 20:13:40 +0000 (22:13 +0200)]
cli: Output prompt and welcome message only when requested by 'hello'

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
10 years agoalsa-mixer: Prefer moving "Capture" before moving boosts
David Henningsson [Fri, 2 Aug 2013 13:03:26 +0000 (15:03 +0200)]
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>
10 years agosample: Apply SPARC-specific condition on SPARC only
Arun Raghavan [Tue, 30 Jul 2013 09:21:59 +0000 (14:51 +0530)]
sample: Apply SPARC-specific condition on SPARC only

Improves correctness, unbreaks software volume in recent Android.

10 years agoFix typos in command_names
Kerrick Staley [Sun, 21 Jul 2013 08:08:43 +0000 (01:08 -0700)]
Fix typos in command_names

10 years agoresampler: Fix peaks resampler's channel handling
Tanu Kaskinen [Wed, 10 Jul 2013 18:48:40 +0000 (21:48 +0300)]
resampler: Fix peaks resampler's channel handling

In the resampling phase the input and output data have the same number
of channels (o_ss.channels).

10 years agoloopback: Increase the maximum allowed latency
Tanu Kaskinen [Tue, 16 Jul 2013 11:12:42 +0000 (14:12 +0300)]
loopback: Increase the maximum allowed latency

Currently the biggest possible sink latency is 10 seconds. The total
latency of the loopback is divided evenly for the source, an
intermediate buffer and the sink, so if I want to test 10 s sink
latency, the total needs to be three times that, i.e. 30 seconds.

10 years agoalsa-ucm: Make combination ports have lower priority
David Henningsson [Fri, 19 Jul 2013 14:38:16 +0000 (16:38 +0200)]
alsa-ucm: Make combination ports have lower priority

Usually, you want to use one input or output at a time: e g,
you expect your speaker to mute when you plug in headphones.

Therefore, the headphones+speaker port should have lower priority
and both headphones and speaker.

A practical formula to do this is 1/x = 1/xa + 1/xb + .. + 1/xn.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
10 years agodaemon.conf: Document new speex-float-1 default
David Henningsson [Tue, 23 Jul 2013 13:58:42 +0000 (15:58 +0200)]
daemon.conf: Document new speex-float-1 default

We document the default values in daemon.conf, but this was not
updated when we changed the default from speex-float-3 to speex-float-1.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
10 years agovala: Add CVolume.set()
Tanu Kaskinen [Thu, 18 Jul 2013 06:16:22 +0000 (09:16 +0300)]
vala: Add CVolume.set()

Thanks to Alberto Ruiz for the patch.

10 years agodbus: Fix invalid dbus_bool_t values
Tanu Kaskinen [Wed, 17 Jul 2013 20:14:24 +0000 (23:14 +0300)]
dbus: Fix invalid dbus_bool_t values

libdbus doesn't like it if it's passed a boolean whose value is not 0
nor 1.