Re: [pulseaudio-discuss] [PATCH] fix the assumption that volume is always positive

2011-05-26 Thread Tanu Kaskinen
On Thu, 2011-05-26 at 09:50 +0100, Colin Guthrie wrote: 'Twas brillig, and Lu Guanqun at 26/05/11 09:49 did gyre and gimble: Add a variable to track whether the actual volume is set or not. Suppose this: min volume: -126max volume: 0 then when user wants to set some constant

Re: [pulseaudio-discuss] How to change profile of bluetooth headset for different applications?

2011-05-26 Thread Tanu Kaskinen
On Mon, 2011-05-23 at 18:18 +0100, Colin Guthrie wrote: How about this: Define a new card property similar in concept to PA_PROP_DEVICE_INTENDED_ROLES (device.intended_roles) called PA_PROP_DEVICE_INTENDED_PROFILE (device.intended_profile). In bluetooth device, when loading a headset that

Re: [pulseaudio-discuss] [PATCH] fix the assumption that volume is always positive

2011-05-26 Thread Tanu Kaskinen
On Thu, 2011-05-26 at 14:08 +0300, Tanu Kaskinen wrote: On Thu, 2011-05-26 at 09:50 +0100, Colin Guthrie wrote: 'Twas brillig, and Lu Guanqun at 26/05/11 09:49 did gyre and gimble: Add a variable to track whether the actual volume is set or not. Suppose this: min volume: -126

Re: [pulseaudio-discuss] [PATCH 1/2] alsa: add jack detection support

2011-05-25 Thread Tanu Kaskinen
Sorry for late reply... On Fri, 2011-05-20 at 09:14 -0500, Jorge Eduardo Candelaria wrote: +if (event-value) +pa_hook_fire(u-core-hooks[PA_CORE_HOOK_JACK_INSERT], jack); +else +pa_hook_fire(u-core-hooks[PA_CORE_HOOK_JACK_REMOVE], jack); Firing core hooks

Re: [pulseaudio-discuss] [PATCH 2/2] alsa: load jack detection module

2011-05-25 Thread Tanu Kaskinen
On Thu, 2011-05-19 at 11:44 -0500, Jorge Eduardo Candelaria wrote: From: Margarita Olaya Cabrera m...@slimlogic.co.uk This patch adds support for udev detection of sound card jack event devices. When a new card is detected, the code now also checks for the presence of any associated input

Re: [pulseaudio-discuss] How to debug a protocol error message?

2011-05-25 Thread Tanu Kaskinen
Sorry for joining the discussion late... I haven't read Pulseaudio mail since last Thursday. On Tue, 2011-05-24 at 09:20 +0100, Colin Guthrie wrote: Yup Maarten's advice is good there. But what is interesting is that our official 0.9.15 version ships with protocol 15, not 16... Your debug

Re: [pulseaudio-discuss] Glitches on null sink?

2011-05-25 Thread Tanu Kaskinen
On Fri, 2011-05-20 at 21:28 +0200, mar...@saepia.net wrote: Hi, I continue to develop my radio audio routing software so I continue to encounter strange bugs. General idea that lies behind my project is to split some processing parts into separate processes. There are many reasons why

Re: [pulseaudio-discuss] [PATCH] alsa-mixer: When setting hw volume, round always up with playback and always down with capture.

2011-05-19 Thread Tanu Kaskinen
On Tue, 2011-05-17 at 19:40 +0100, Colin Guthrie wrote: Just to report that a modified version of that patch does indeed fix the problem for me. What do you think overall? Should we try and hunt down the problems with the conversion or should this patch be included? I think it would make

Re: [pulseaudio-discuss] [PATCH] alsa-mixer: When setting hw volume, round always up with playback and always down with capture.

2011-05-19 Thread Tanu Kaskinen
On Tue, 2011-05-17 at 12:13 +0100, Colin Guthrie wrote: Thanks, I'll test this patch and see if it helps with my test case. Assuming that it does, is this something we should really push to alsa lib? When I first encountered the problem I did start hacking away at alsa lib looking for the

Re: [pulseaudio-discuss] Jack detection (was: Re: [PATCHv3 0/4] Read and store UCM data as proplist)

2011-05-19 Thread Tanu Kaskinen
On Tue, 2011-05-17 at 13:44 +0200, David Henningsson wrote: Agree with the port property. About the port vs profile question, I think we might think that backwards from a user's perspective. Conceptually I'd say we select port first (manually or automatic; doesn't matter for this

Re: [pulseaudio-discuss] [PATCH 1/2] alsa: add jack detection support

2011-05-19 Thread Tanu Kaskinen
I tried to apply the patch for easier review in meld, but unfortunately it seems that some helpful software has eaten the first space on lines that begin with one or more spaces. Because of that, git am doesn't accept the patch. I'll review this anyway, without meld. Overall comments: there is

Re: [pulseaudio-discuss] [PATCH] alsa-mixer: When setting hw volume, round always up with playback and always down with capture.

2011-05-17 Thread Tanu Kaskinen
On Mon, 2011-05-16 at 21:22 +0100, Colin Guthrie wrote: OK, here is the debug output from my run using this volume approach As you can see there are several points where the message: Written HW volume did not match with the request is shown. This is shown quite clearly when writing the

[pulseaudio-discuss] [PATCH] alsa-mixer: When setting hw volume, round always up with playback and always down with capture.

2011-05-15 Thread Tanu Kaskinen
This was discussed on the mailing list: https://tango.0pointer.de/pipermail/pulseaudio-discuss/2011-May/010091.html --- src/modules/alsa/alsa-mixer.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c index

[pulseaudio-discuss] [PATCH] bluetooth: Add missing return statement.

2011-05-14 Thread Tanu Kaskinen
--- src/modules/bluetooth/module-bluetooth-device.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/src/modules/bluetooth/module-bluetooth-device.c b/src/modules/bluetooth/module-bluetooth-device.c index 086fce9..ae522bc 100644 ---

[pulseaudio-discuss] [PATCH] loopback: Add a modarg for disabling remixing.

2011-05-14 Thread Tanu Kaskinen
--- src/modules/module-loopback.c | 18 +- 1 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/modules/module-loopback.c b/src/modules/module-loopback.c index 9a8640b..024337f 100644 --- a/src/modules/module-loopback.c +++ b/src/modules/module-loopback.c @@ -59,7

[pulseaudio-discuss] Reverting ade0a6f88464d8aecf83982d400ccfc402341920

2011-05-13 Thread Tanu Kaskinen
Hello, Should this commit be reverted? http://git.0pointer.de/?p=pulseaudio.git;a=commit;h=ade0a6f88464d8aecf83982d400ccfc402341920 I don't know what problem that commit solves, but it introduces a new problem: if Pulseaudio requests a volume that is above 0dB in the alsa volume element scale,

Re: [pulseaudio-discuss] Is there any way to remap source channels?

2011-05-13 Thread Tanu Kaskinen
On Fri, 2011-05-13 at 11:30 +0200, mar...@saepia.net wrote: Hi, is there any way to remap source channels? I need the same functionality as provided by module-remap-sink, but for sources - I use multichannel soundcard (RME Hammerfall) and I want to create virtual sources that map to

Re: [pulseaudio-discuss] Is there any way to remap source channels?

2011-05-13 Thread Tanu Kaskinen
On Fri, 2011-05-13 at 14:14 +0200, mar...@saepia.net wrote: Why should I prevent remixing? Can't I just use module-loopback with channel_map set? I think this is what happens (I haven't tested): if you have non-aux channels on the sound card, let's say front-left, front-right, rear-left and

Re: [pulseaudio-discuss] Reverting ade0a6f88464d8aecf83982d400ccfc402341920

2011-05-13 Thread Tanu Kaskinen
On Fri, 2011-05-13 at 17:29 +0200, David Henningsson wrote: In short; if we e g have Mic Boost levels at (0dB, 20dB, 40dB and 60dB) and the user wants 30 dB, better have 20dB in hardware and +10dB in software than 40dB in hardware and -10dB in software, as the latter one is more likely to

Re: [pulseaudio-discuss] Is there any way to remap source channels?

2011-05-13 Thread Tanu Kaskinen
On Fri, 2011-05-13 at 17:05 +0100, Colin Guthrie wrote: FWIW, some modules, like module-remap-sink take a remix=yes|no argument to control this behaviour even when using standard channel names. module-loopback should have a similar argument, but it doesn't... -- Tanu

Re: [pulseaudio-discuss] realtime kernel RLIMIT_RTTIME crashes, rewinds

2011-05-04 Thread Tanu Kaskinen
Sorry for the delayed reply. On Wed, 2011-04-27 at 13:23 +0300, Dan Muresan wrote: I've patched (as in attachment) src/daemon/main.c to set the soft rttime limit lower than the hard limit. This way I was able to get a backtrace in gdb when pulseaudio received SIGXCPU due to excessive

[pulseaudio-discuss] [PATCH] match: Support for both merging and replacing proplist updates.

2011-04-29 Thread Tanu Kaskinen
This patch adds a new update mode specifier that can be optionally given in match rules after the regexp. Propertly list updates triggered by the rule will honour the given mode. The two allowed modes are 'merge' and 'replace', corresponding to PA_UPDATE_MERGE and PA_UPDATE_REPLACE respectively.

[pulseaudio-discuss] [PATCH 0/2] Fixing module-dbus-protocol unloading

2011-04-29 Thread Tanu Kaskinen
There were a couple of crash bugs in the module-dbus-protocol unloading code, which became visible when unloading the module while there were still clients connected. Tanu Kaskinen (2): dbus: Fix connection idxset freeing when unloading the module. dbus: Fix the order of freeing stuff when

[pulseaudio-discuss] [PATCH 2/2] dbus: Fix the order of freeing stuff when unloading module-dbus-protocol.

2011-04-29 Thread Tanu Kaskinen
--- src/modules/dbus/module-dbus-protocol.c | 12 +--- 1 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/modules/dbus/module-dbus-protocol.c b/src/modules/dbus/module-dbus-protocol.c index 276c6ba..4969585 100644 --- a/src/modules/dbus/module-dbus-protocol.c +++

[pulseaudio-discuss] [PATCH 1/2] dbus: Fix connection idxset freeing when unloading the module.

2011-04-29 Thread Tanu Kaskinen
If u-connections isn't empty when module-dbus-protocol is unloaded, then connection_free() is called for the remaining connections when the idxset is freed. connection_free() tries to remove the connection from the idxset, but that fails, because the item has already been removed from the idxset

Re: [pulseaudio-discuss] [PATCH] stream-restore: Enable database dumping if DEBUG_VOLUME is defined.

2011-04-28 Thread Tanu Kaskinen
On Thu, 2011-04-28 at 12:48 +0300, Colin Guthrie wrote: 'Twas brillig, and Tanu Kaskinen at 27/04/11 11:08 did gyre and gimble: From: Tanu Kaskinen ext-tanu.kaski...@nokia.com --- src/modules/module-stream-restore.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions

[pulseaudio-discuss] [PATCH] stream-restore: Enable database dumping if DEBUG_VOLUME is defined.

2011-04-27 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com --- src/modules/module-stream-restore.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/module-stream-restore.c b/src/modules/module-stream-restore.c index c1baf8f..56672f7 100644 --- a/src/modules/module

[pulseaudio-discuss] [PATCH] module: new null-source module

2011-04-27 Thread Tanu Kaskinen
From: Marc-André Lureau marcandre.lur...@gmail.com --- src/Makefile.am |6 + src/modules/module-null-source.c | 294 ++ 2 files changed, 300 insertions(+), 0 deletions(-) create mode 100644 src/modules/module-null-source.c diff --git

Re: [pulseaudio-discuss] [PATCH] module: new null-source module

2011-04-27 Thread Tanu Kaskinen
On Wed, 2011-04-27 at 14:50 +0300, Tanu Kaskinen wrote: From: Marc-André Lureau marcandre.lur...@gmail.com --- src/Makefile.am |6 + src/modules/module-null-source.c | 294 ++ 2 files changed, 300 insertions(+), 0 deletions

Re: [pulseaudio-discuss] how to set buffer attributes in 0.9.15

2011-04-25 Thread Tanu Kaskinen
On Thu, 2011-04-21 at 22:48 -0700, sohail abbasi wrote: hi everyone, I am stuck in the pulseaudio programing, I am adding pulseaudio support in my existing application.Design of the application is synchronous and multithreaded. I need exactly 320 samples (320*4 bytes) for reading and

[pulseaudio-discuss] [PATCH] stream-restore: simple fallback volume table

2011-04-21 Thread Tanu Kaskinen
From: Marc-André Lureau marcandre.lur...@gmail.com Comment from Tanu Kaskinen: I made a few tweaks, so blame me if the patch contains bugs. --- src/modules/module-stream-restore.c | 97 ++- 1 files changed, 95 insertions(+), 2 deletions(-) diff --git a/src

Re: [pulseaudio-discuss] [PATCH] stream-restore: simple fallback volume table

2011-04-21 Thread Tanu Kaskinen
On Thu, 2011-04-21 at 14:31 +0300, Tanu Kaskinen wrote: From: Marc-André Lureau marcandre.lur...@gmail.com Comment from Tanu Kaskinen: I made a few tweaks, so blame me if the patch contains bugs. The commit message is a bit short... The purpose of this patch is to make it possible

Re: [pulseaudio-discuss] [PATCH v2] call-state-tracker: New component.

2011-04-20 Thread Tanu Kaskinen
On Wed, 2011-04-20 at 11:36 +0300, Colin Guthrie wrote: The api object header could be located in src/extra_apis - that would make the api not directly dependent on a particular module. If the API is not dependant on a particular module, what code calls pa_extra_api_register? I'd be

[pulseaudio-discuss] [PATCH] match: don't double free in case of missing table file

2011-04-20 Thread Tanu Kaskinen
From: Marc-André Lureau marcandre.lur...@gmail.com --- src/modules/module-match.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/src/modules/module-match.c b/src/modules/module-match.c index c8f2706..3eba149 100644 --- a/src/modules/module-match.c +++

[pulseaudio-discuss] [PATCH] match: match rule earlier, in SINK_INPUT_NEW

2011-04-20 Thread Tanu Kaskinen
From: Marc-André Lureau marcandre.lur...@gmail.com --- src/modules/module-match.c | 35 +-- 1 files changed, 13 insertions(+), 22 deletions(-) diff --git a/src/modules/module-match.c b/src/modules/module-match.c index 3eba149..b3316d4 100644 ---

Re: [pulseaudio-discuss] [PATCH v2] call-state-tracker: New component.

2011-04-20 Thread Tanu Kaskinen
On Wed, 2011-04-20 at 15:19 +0300, Colin Guthrie wrote: OK, so the manager object is separate but kept in the core? Seems fine by me to keep things neatly separated. Yep. I thinking of taking a pop at this at some point soon (if you don't beat me to it), so can we decide on the name now?

Re: [pulseaudio-discuss] RFC: Filter module loader

2011-04-20 Thread Tanu Kaskinen
On Fri, 2011-04-15 at 20:55 +0200, Colin Guthrie wrote: Also, I had to apply this patch to equalizer-sink to prevent it from crashing the server on unload: diff --git a/src/modules/module-equalizer-sink.c b/src/modules/module-equalizer-sink.c index 0bbb23a..611f7dd 100644 ---

[pulseaudio-discuss] [PATCH] protocol-dbus: Fix some memory management bugs.

2011-04-20 Thread Tanu Kaskinen
There were several memory leaks. In addition to those, pa_dbus_protocol_add_interface() used a string from the caller as a key to a hashmap, instead of a copy of the string. This caused trouble when the caller freed the string while the key was still in use in the hashmap. ---

Re: [pulseaudio-discuss] glib functions on PA

2011-04-20 Thread Tanu Kaskinen
On Thu, 2011-04-21 at 10:13 +0530, Arun Raghavan wrote: On Wed, 2011-04-20 at 23:26 -0500, Margarita Olaya wrote: Hi, The initial implementation of jack detection is using threads and simple file operations like open, close and read currently I'm looking into using pa_threads and glib

[pulseaudio-discuss] [PATCH] tests: improve resampler test

2011-04-19 Thread Tanu Kaskinen
From: Marc-André Lureau marcandre.lur...@gmail.com --- src/tests/resampler-test.c | 207 +-- 1 files changed, 197 insertions(+), 10 deletions(-) diff --git a/src/tests/resampler-test.c b/src/tests/resampler-test.c index 82198b5..69d7ab0 100644 ---

Re: [pulseaudio-discuss] [PATCH v2] call-state-tracker: New component.

2011-04-18 Thread Tanu Kaskinen
On Mon, 2011-04-18 at 11:35 +0300, Colin Guthrie wrote: I'd be interested in implementing at some point (no promises or timelines) a small framework for making inter-module communication easier, or at least cleaner (this kind of hacks in pulsecore are actually very easy to work with, but

[pulseaudio-discuss] [PATCH] sink-input: Check flat volume with pa_sink_flat_volume_enabled().

2011-04-15 Thread Tanu Kaskinen
Checking just the flag doesn't work if the sink uses volume sharing, because such sinks never have PA_SINK_FLAT_VOLUME set. --- src/pulsecore/sink-input.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pulsecore/sink-input.c b/src/pulsecore/sink-input.c index

Re: [pulseaudio-discuss] pulseaudio

2011-04-12 Thread Tanu Kaskinen
On Tue, 2011-04-12 at 12:30 -0400, Sean McNamara wrote: Hi, On Tue, Apr 12, 2011 at 12:15 PM, duportail po...@telenet.be wrote: Try to test the new xubuntu 11.04 with kde on a multi-user system. The first user (for example user1) can log in and gets a default sink from pulse. The

Re: [pulseaudio-discuss] [PATCH] sink-input: Don't assert while trying to get non-readable volume

2011-04-11 Thread Tanu Kaskinen
On Sun, 2011-04-10 at 16:52 +0530, Arun Raghavan wrote: Since no clients currently handle non-readable volumes, we handle this condition more gracefully (return PA_VOLUME_NORM). In the future, this could probably changed into an error return instead of an assert so that a non-conformant client

Re: [pulseaudio-discuss] [PATCH] call-state-tracker: New component.

2011-04-06 Thread Tanu Kaskinen
On Wed, 2011-04-06 at 00:57 +0300, Maarten Bosmans wrote: What are the users of this state tracker? Is it only some out-of-tree Meego modules? Are you planning to submit those too? At least a snippet of how it should be used would be nice. The users are mentioned in call-state-tracker.h. I

[pulseaudio-discuss] [PATCH v2] call-state-tracker: New component.

2011-04-06 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com See call-state-tracker.h for details. Changed in patch v2: Don't take a reference of pa_core. The previous version would have reintroduced the bug that was fixed in 1e381fbf. --- src/Makefile.am|1 + src/pulsecore/call

Re: [pulseaudio-discuss] [PATCH] call-state-tracker: New component.

2011-04-06 Thread Tanu Kaskinen
On Wed, 2011-04-06 at 11:41 +0300, Tanu Kaskinen wrote: On Wed, 2011-04-06 at 00:57 +0300, Maarten Bosmans wrote: What are the users of this state tracker? Is it only some out-of-tree Meego modules? Are you planning to submit those too? At least a snippet of how it should be used would

Re: [pulseaudio-discuss] [PATCH v2] call-state-tracker: New component.

2011-04-06 Thread Tanu Kaskinen
On Wed, 2011-04-06 at 14:23 +0100, Colin Guthrie wrote: 'Twas brillig, and Tanu Kaskinen at 06/04/11 12:33 did gyre and gimble: +/* This is a shared singleton object, currently used by Meego's voice and + * policy enforcement modules. The purpose of the object is just to maintain

[pulseaudio-discuss] [PATCH] stream-restore: add version to new entry.

2011-04-05 Thread Tanu Kaskinen
From: Harri Mähönen ext-harri.maho...@nokia.com --- src/modules/module-stream-restore.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/modules/module-stream-restore.c b/src/modules/module-stream-restore.c index 8edfee0..d27982b 100644 ---

[pulseaudio-discuss] [PATCH] call-state-tracker: New component.

2011-04-05 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com --- src/Makefile.am|1 + src/pulsecore/call-state-tracker.c | 127 src/pulsecore/call-state-tracker.h | 54 +++ 3 files changed, 182 insertions(+), 0 deletions(-) create

[pulseaudio-discuss] [PATCH] bluetooth: drop data every 500ms on oor condition

2011-04-04 Thread Tanu Kaskinen
From: Marc-André Lureau marc-andre.lur...@nokia.com --- src/modules/bluetooth/module-bluetooth-device.c | 25 -- 1 files changed, 14 insertions(+), 11 deletions(-) diff --git a/src/modules/bluetooth/module-bluetooth-device.c

[pulseaudio-discuss] [PATCH] alsa: Fix log output to inform about positive base volumes correctly.

2011-04-04 Thread Tanu Kaskinen
This fix was done for _set_port_cb() already, but the first fix didn't fix setup_mixer(). Now that's done too. --- src/modules/alsa/alsa-sink.c |5 + src/modules/alsa/alsa-source.c |5 + 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/src/modules/alsa/alsa-sink.c

Re: [pulseaudio-discuss] how to read exactly 320 samples

2011-04-04 Thread Tanu Kaskinen
On Mon, 2011-04-04 at 00:27 -0700, sohail abbasi wrote: Hi , everyone I am new to audio programing(as well pulseaudio). I have to add pulseaudio support in an application already working with ALSA and OSS. the designe of my application is such that I have to read 320 samples in read

Re: [pulseaudio-discuss] [PATCH 5/5] bluetooth: Refuse to use the HSP profile if there is some other HSP device active.

2011-04-01 Thread Tanu Kaskinen
On Thu, 2011-03-31 at 15:30 +0300, Tanu Kaskinen wrote: On Thu, 2011-03-31 at 15:11 +0300, Tanu Kaskinen wrote: If no volunteers pop up, I guess I'll have to get a bluetooth dongle for my desktop so that I can test this myself. Never mind, I found a dongle already - I'll test it tomorrow

[pulseaudio-discuss] [PATCH] bluetooth: Fix HSP volume handling.

2011-03-31 Thread Tanu Kaskinen
Previously the userdata for the volume callbacks was saved to pa_core.shared only once when loading module-bluetooth-device, and only when the SCO over PCM feature was used. That breaks volume handling in cases where the HSP profile is used without the SCO over PCM setup. Now the userdata is set

Re: [pulseaudio-discuss] [PATCH 5/5] bluetooth: Refuse to use the HSP profile if there is some other HSP device active.

2011-03-31 Thread Tanu Kaskinen
On Thu, 2011-03-31 at 15:11 +0300, Tanu Kaskinen wrote: If no volunteers pop up, I guess I'll have to get a bluetooth dongle for my desktop so that I can test this myself. Never mind, I found a dongle already - I'll test it tomorrow. -- Tanu

Re: [pulseaudio-discuss] [PATCH 5/5] bluetooth: Refuse to use the HSP profile if there is some other HSP device active.

2011-03-30 Thread Tanu Kaskinen
On Mon, 2011-03-28 at 18:17 +0300, Luiz Augusto von Dentz wrote: There is a similar policy in BlueZ already for this and it is configurable via /etc/bluetooth/audio.conf, so I don't think hardcoding this on PA would do any better. Ah, excellent, I didn't know that. So the HSP profile locking

Re: [pulseaudio-discuss] [PATCH 5/5] bluetooth: Refuse to use the HSP profile if there is some other HSP device active.

2011-03-30 Thread Tanu Kaskinen
On Tue, 2011-03-29 at 23:16 +0300, Colin Guthrie wrote: 'Twas brillig, and Luiz Augusto von Dentz at 28/03/11 16:17 did gyre and gimble: There is a similar policy in BlueZ already for this and it is configurable via /etc/bluetooth/audio.conf, so I don't think hardcoding this on PA would do

[pulseaudio-discuss] [PATCH 0/5] SCO over PCM fixes

2011-03-28 Thread Tanu Kaskinen
(3): bluetooth: use sco_sink/source to start with right state bluetooth: fix set_volume_cb on sco over pcm bluetooth: restore original sco_{sink,src}-set_volume when unloading Tanu Kaskinen (2): bluetooth: Drop all #ifdef NOKIA directives. bluetooth: Refuse to use the HSP profile

[pulseaudio-discuss] [PATCH 1/5] bluetooth: Drop all #ifdef NOKIA directives.

2011-03-28 Thread Tanu Kaskinen
The #ifdefs only added clutter. I don't see any reason to not compile the SCO over PCM support in all the time. --- src/modules/bluetooth/module-bluetooth-device.c | 57 +++--- 1 files changed, 8 insertions(+), 49 deletions(-) diff --git

[pulseaudio-discuss] [PATCH 2/5] bluetooth: use sco_sink/source to start with right state

2011-03-28 Thread Tanu Kaskinen
From: Marc-André Lureau marc-andre.lur...@nokia.com Note from Tanu Kaskinen: I resolved some conflicts with newer upstream code, so if this patch is broken, blame me.. --- src/modules/bluetooth/module-bluetooth-device.c | 39 +- 1 files changed, 23 insertions(+), 16

[pulseaudio-discuss] [PATCH 4/5] bluetooth: restore original sco_{sink, src}-set_volume when unloading

2011-03-28 Thread Tanu Kaskinen
From: Marc-André Lureau marc-andre.lur...@nokia.com --- src/modules/bluetooth/module-bluetooth-device.c |6 ++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/modules/bluetooth/module-bluetooth-device.c b/src/modules/bluetooth/module-bluetooth-device.c index

[pulseaudio-discuss] [PATCH 3/5] bluetooth: fix set_volume_cb on sco over pcm

2011-03-28 Thread Tanu Kaskinen
From: Marc-André Lureau marc-andre.lur...@nokia.com The current implementation is totally bogus, it cast the over_sink userdata to the bluetooth-device userdata... It was failing nicely because the previous code had a gentle safe-guard in u-profile == PROFILE_HSP, and u-profile was just random.

[pulseaudio-discuss] [PATCH 5/5] bluetooth: Refuse to use the HSP profile if there is some other HSP device active.

2011-03-28 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com --- src/modules/bluetooth/module-bluetooth-device.c | 126 +-- 1 files changed, 93 insertions(+), 33 deletions(-) diff --git a/src/modules/bluetooth/module-bluetooth-device.c b/src/modules/bluetooth/module-bluetooth-device.c

[pulseaudio-discuss] [PATCH] .gitignore: Add ChangeLog and src/envelope-test to the ignore list

2011-03-27 Thread Tanu Kaskinen
--- .gitignore |1 + src/.gitignore |1 + 2 files changed, 2 insertions(+), 0 deletions(-) diff --git a/.gitignore b/.gitignore index 85c0fe5..3a840d9 100644 --- a/.gitignore +++ b/.gitignore @@ -27,3 +27,4 @@ libtool ltmain.sh missing stamp-* +ChangeLog diff --git

Re: [pulseaudio-discuss] [PATCH] .gitignore: Add ChangeLog and src/envelope-test to the ignore list

2011-03-27 Thread Tanu Kaskinen
On Sun, 2011-03-27 at 20:19 +0530, Arun Raghavan wrote: On Sun, 2011-03-27 at 17:39 +0300, Tanu Kaskinen wrote: [...] diff --git a/src/.gitignore b/src/.gitignore index e56c225..1f959ec 100644 --- a/src/.gitignore +++ b/src/.gitignore @@ -66,3 +66,4 @@ start-pulseaudio-x11 start

[pulseaudio-discuss] [PATCH] .gitignore: Add ChangeLog to the ignore list.

2011-03-27 Thread Tanu Kaskinen
--- .gitignore |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/.gitignore b/.gitignore index 85c0fe5..3a840d9 100644 --- a/.gitignore +++ b/.gitignore @@ -27,3 +27,4 @@ libtool ltmain.sh missing stamp-* +ChangeLog -- 1.7.4.1

[pulseaudio-discuss] [PATCH] alsa-mixer: Get rid of a compiler warning.

2011-03-27 Thread Tanu Kaskinen
On 64-bit systems LONG_MAX is greater than the largest possible value of a uint32_t variable, which caused the compiler to warn about a comparison that is always false. On 32-bit systems pa_atou() can return a value that will overflow when assigned to e-volume_limit, which has type long, so the

Re: [pulseaudio-discuss] [PATCH] alsa-mixer: Get rid of a compiler warning.

2011-03-27 Thread Tanu Kaskinen
On Sun, 2011-03-27 at 21:20 +0300, Tanu Kaskinen wrote: @@ -2018,14 +2018,8 @@ int pa_atoi(const char *s, int32_t *ret_i) { pa_assert(s); pa_assert(ret_i); -errno = 0; -l = strtol(s, x, 0); - -if (!x || *x || errno) { -if (!errno) -errno

[pulseaudio-discuss] [PATCH] alsa-mixer: Get rid of a compiler warning.

2011-03-27 Thread Tanu Kaskinen
On 64-bit systems LONG_MAX is greater than the largest possible value of a uint32_t variable, which caused the compiler to warn about a comparison that is always false. On 32-bit systems pa_atou() can return a value that will overflow when assigned to e-volume_limit, which has type long, so the

[pulseaudio-discuss] [PATCH] sink-input: Add volume_writable to pa_sink_input.

2011-03-27 Thread Tanu Kaskinen
This is pretty cosmetic change; there's no actual functionality added. Previously the volume_writable information was available through the pa_sink_input_is_volume_writable() function, but I find it cleaner to have a real variable. The sink input introspection variable name was also changed from

Re: [pulseaudio-discuss] Current problems with git master

2011-03-25 Thread Tanu Kaskinen
On Fri, 2011-03-25 at 09:11 +, Colin Guthrie wrote: This patch should fix up these issues right? Yep, seems correct to me. -- Tanu ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de

Re: [pulseaudio-discuss] Current problems with git master

2011-03-25 Thread Tanu Kaskinen
On Fri, 2011-03-25 at 23:09 +, Colin Guthrie wrote: Does this patch look OK to everyone (especially Tanu!) Looks ok to me! Thanks for fixing this. -- Tanu ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de

Re: [pulseaudio-discuss] Current problems with git master

2011-03-25 Thread Tanu Kaskinen
On Sat, 2011-03-26 at 00:13 +, Colin Guthrie wrote: FWIW, the attached patch seems to work for me... simply not ref'ing the core. If this is OK, then I'll push it. Yep, my bad. I think there's a rule that object A shall not ref object B if B owns A. And here core owns everything, including

[pulseaudio-discuss] [PATCH] loopback: Always use the trivial resampler.

2011-03-24 Thread Tanu Kaskinen
Adjusting the sample rate is done in the IO thread, which can cause interruptions in the audio if the adjustment requires heavy computation. The trivial resampler is guaranteed to be light on the cpu. It would be better to adjust the sample rate in some other thread (FWIW, module-combine uses the

Re: [pulseaudio-discuss] [PATCH] loopback: Always use the trivial resampler.

2011-03-24 Thread Tanu Kaskinen
On Thu, 2011-03-24 at 15:31 +0200, pl bossart wrote: On Thu, Mar 24, 2011 at 8:16 AM, Tanu Kaskinen tanu.kaski...@digia.com wrote: Adjusting the sample rate is done in the IO thread, which can cause interruptions in the audio if the adjustment requires heavy computation. The trivial

Re: [pulseaudio-discuss] [PATCH 1/2] pactl: Accept more volume specification formats

2011-03-24 Thread Tanu Kaskinen
On Thu, 2011-03-24 at 22:22 +0530, Arun Raghavan wrote: On Thu, 2011-03-24 at 13:07 +, Colin Guthrie wrote: 'Twas brillig, and Maarten Bosmans at 24/03/11 12:44 did gyre and gimble: 2011/3/24 Maarten Bosmans mkbosm...@gmail.com: With this you can specify the volume with 6554, 10%,

Re: [pulseaudio-discuss] [PATCH] loopback: Always use the trivial resampler.

2011-03-24 Thread Tanu Kaskinen
On Thu, 2011-03-24 at 09:09 -0500, pl bossart wrote: The sink may be running in a low-latency mode even if the loopback stream doesn't have any latency requirements - there may be other streams active at the same time with stricter timing requirements. FWIW, the practical case here was a

Re: [pulseaudio-discuss] Current problems with git master

2011-03-24 Thread Tanu Kaskinen
On Thu, 2011-03-24 at 21:30 +, Colin Guthrie wrote: If someone could double check, I'd appreciate it (seeing as I'd rather any bugs in my commit last less than a year and a half!!) Problems found: The first process: daemon_pipe is not closed if the first fork() call fails. Even if it

[pulseaudio-discuss] [PATCH 0/2] Rebased bluetooth patches

2011-03-23 Thread Tanu Kaskinen
Colin wrote: Can you rebase these two on git master please? I just merged a whole bunch of changes from BT guys and these both fail now. Sure, refreshed patches coming. Tanu Kaskinen (2): bluetooth: Don't log an error if an endpoint type is disabled. bluetooth: Get rid of warnings about

[pulseaudio-discuss] [PATCH 1/2 rebased] bluetooth: Don't log an error if an endpoint type is disabled.

2011-03-23 Thread Tanu Kaskinen
It's perfectly normal for BlueZ to disable some endpoint types, so printing a log message at error level isn't a good idea. For facilitating an informative message in case some endpoint type is disabled, the send_and_add_to_pending() function interface is also changed to be more generic (the

[pulseaudio-discuss] [PATCH 2/2 rebased] bluetooth: Get rid of warnings about unused stuff when building against a D-Bus version that doesn't have fd-passing support.

2011-03-23 Thread Tanu Kaskinen
--- src/modules/bluetooth/bluetooth-util.c | 10 ++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/src/modules/bluetooth/bluetooth-util.c b/src/modules/bluetooth/bluetooth-util.c index a79ff91..f1c7c4c 100644 --- a/src/modules/bluetooth/bluetooth-util.c +++

[pulseaudio-discuss] [PATCH] alsa-mixer: Check that the kernel driver returns consistent limits with both snd_mixer_selem_get_*_dB_range() and _ask_*_vol_dB().

2011-03-23 Thread Tanu Kaskinen
The check is inspired by a driver that returned higher dB limit from snd_mixer_selem_get_playback_dB_range() than what _ask_playback_vol_dB() returned at maximum integer volume. --- src/modules/alsa/alsa-mixer.c | 37 + 1 files changed, 37 insertions(+), 0

[pulseaudio-discuss] [PATCH] alsa-mixer: Make sure that SND_MIXER_SCHN_UNKNOWN isn't used when indexing e-masks.

2011-03-23 Thread Tanu Kaskinen
SND_MIXER_SCHN_UNKNOWN is defined as -1, so that's not a good array index... --- src/modules/alsa/alsa-mixer.c | 13 +++-- 1 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c index b425ce5..c9adbb0 100644 ---

Re: [pulseaudio-discuss] ALSA or PulseAudio for low-latency voice?

2011-03-20 Thread Tanu Kaskinen
On Sun, 2011-03-20 at 11:07 +0100, David Henningsson wrote: On 2011-03-19 17:45, Philip Jägenstedt wrote: Hi PulseAudionauts, I've been meaning to experiment a bit with low-latency voice codecs and naturally want to add as little latency as possible to what is imposed by the codec on

Re: [pulseaudio-discuss] [PATCH 1/5] module-coreaudio-detect: fix pa__done()

2011-03-20 Thread Tanu Kaskinen
On Sun, 2011-03-20 at 18:39 +0100, Daniel Mack wrote: void pa__done(pa_module *m) { -struct userdata *u; +struct userdata *u = m-userdata; struct ca_device *dev = u-devices; AudioObjectPropertyAddress property_address; -pa_assert(m); -pa_assert_se(u =

Re: [pulseaudio-discuss] More patches for OS X

2011-03-20 Thread Tanu Kaskinen
On Sun, 2011-03-20 at 18:39 +0100, Daniel Mack wrote: osx: re-order module locations This patch didn't reach the list for some reason. -- Tanu ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de

Re: [pulseaudio-discuss] [PATCH 3/5] osx: add -headerpad_max_install_names to LDFLAGS

2011-03-20 Thread Tanu Kaskinen
On Sun, 2011-03-20 at 18:39 +0100, Daniel Mack wrote: This is needed for sufficient padding of library names in linked binaries. --- src/Makefile.am |5 + 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index ff98ddb..c182483 100644

[pulseaudio-discuss] [PATCH 2/2] bluetooth: Get rid of warnings about unused stuff when building against a D-Bus version that doesn't have fd-passing support.

2011-03-18 Thread Tanu Kaskinen
--- src/modules/bluetooth/bluetooth-util.c | 10 -- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/modules/bluetooth/bluetooth-util.c b/src/modules/bluetooth/bluetooth-util.c index 68ee808..cae7f16 100644 --- a/src/modules/bluetooth/bluetooth-util.c +++

[pulseaudio-discuss] [PATCH 2/2] alsa-mixer: Refactoring: merge element_mute_volume(), element_zero_volume() and element_apply_constant_volume() into a single function.

2011-03-17 Thread Tanu Kaskinen
--- src/modules/alsa/alsa-mixer.c | 102 ++--- 1 files changed, 35 insertions(+), 67 deletions(-) diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa-mixer.c index 2893b47..aa3422a 100644 --- a/src/modules/alsa/alsa-mixer.c +++

Re: [pulseaudio-discuss] [WIP] Passthrough support

2011-03-16 Thread Tanu Kaskinen
On Tue, 2011-03-15 at 17:36 -0500, pl bossart wrote: I pushed your change along with a fix for the assert you saw to my tree as well. I tested the latest batch of patches with AC3/SPDIF this time. Works well in general, however I found some interesting points: - in Rhythmbox, the

Re: [pulseaudio-discuss] 2ch - 6ch upmixing with flatvolumes

2011-03-12 Thread Tanu Kaskinen
On Sat, 2011-03-12 at 14:46 +, Colin Guthrie wrote: Hi, I was working with Valodim on IRC and stumbled on an issue with flat volumes on 5.1 sinks when playing a 2ch sink input. I try to adjust the Rear left+right to be 0, but it just doesn't let me. It seems the flat volume logic

Re: [pulseaudio-discuss] [RFC] allow conditionals in config input files like default.pa.in

2011-03-12 Thread Tanu Kaskinen
Hi Maarten, Did you ever get any feedback? At least there are no replies on the mailing list. On Fri, 2011-03-04 at 00:26 +0100, Maarten Bosmans wrote: It would be nice to have the ability to use @if HAVE_FEATURE@ in the configuration file templates. You could see it either as an extension of

[pulseaudio-discuss] [PATCH 1/2] alsa-mixer: Implement support for setting element specific upper limits for volume.

2011-03-10 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com This feature is mainly useful in embedded systems that have built-in speakers. In such situations the full audio path is known beforehand, so it's possible to know what is the maximum sensible volume, and any higher volume can be disabled

[pulseaudio-discuss] [PATCH 2/2] alsa-mixer: When figuring out the max_dB of a path, use only channels that are used by the path elements.

2011-03-10 Thread Tanu Kaskinen
Without this, p-max_dB could never be less than 0 dB, because the loop at the end of pa_alsa_path_probe() would reset p-max_dB to 0 as soon as the loop encountered a channel that wasn't touched by any element. --- src/modules/alsa/alsa-mixer.c | 13 + 1 files changed, 9

[pulseaudio-discuss] [PATCH 2/7 v2] alsa-mixer: Use decibel fixes when getting and setting decibel volumes.

2011-03-09 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com --- src/modules/alsa/alsa-mixer.c | 260 - src/modules/alsa/alsa-mixer.h |8 +- 2 files changed, 212 insertions(+), 56 deletions(-) diff --git a/src/modules/alsa/alsa-mixer.c b/src/modules/alsa/alsa

Re: [pulseaudio-discuss] [PATCH 0/7] Working around bad decibel information

2011-03-09 Thread Tanu Kaskinen
On Wed, 2011-03-09 at 12:53 +0200, David Henningsson wrote: On 2011-03-04 16:42, Tanu Kaskinen wrote: Here's a pile of patches. The first two implement the concept of decibel fixes for alsa devices. A decibel fix is basically a table that maps the raw volume steps of a mixer element

Re: [pulseaudio-discuss] Volume algorithm

2011-03-06 Thread Tanu Kaskinen
On Sat, 2011-03-05 at 11:29 +, Tarantism wrote: On Sat, 2011-03-05 at 11:08 +, Colin Guthrie wrote: 'Twas brillig, and Tarantism at 04/03/11 22:23 did gyre and gimble: I need to implement a volume scaling in a pulse module. I have 0-100 input values. What algorithm does pulse

[pulseaudio-discuss] [PATCH 0/7] Working around bad decibel information

2011-03-04 Thread Tanu Kaskinen
the decibel fix patches. The pacat memory leak fix hasn't been verified that it works (it's just a quick fix to a seemingly obvious, but difficult to test bug), otherwise I have tested the fixes. Tanu Kaskinen (7): alsa-mixer: Add DecibelFix section to the profile set config file format. alsa

[pulseaudio-discuss] [PATCH 1/7] alsa-mixer: Add DecibelFix section to the profile set config file format.

2011-03-04 Thread Tanu Kaskinen
From: Tanu Kaskinen ext-tanu.kaski...@nokia.com This commit only implements the parser, the decibel fix data is not yet used for anything. --- src/modules/alsa/alsa-mixer.c| 223 +- src/modules/alsa/alsa-mixer.h| 19 ++ src/modules

  1   2   3   4   >