Re: [pulseaudio-discuss] New feature in the works: volume sharing
On Sun, 2011-02-13 at 22:05 +0200, Colin Guthrie wrote: With this push based approach, you do loose some individual granularity, but the net volume of the underlying h/w should be the same as your approach. What granularity would I lose? I think your suggested logic would be quite equivalent to the one that I originally proposed. The concern I have with the approach outlined, is that it adds complexity to the core and I'm not 100% sure how far the chain can go (e.g. can you have a filter-sink1-filter-sink2-filter-sink3-hw-sink pipeline? - with a push model this is possible). It's possible with the pull model too - the filter sinks are always traversed recursively. About complexity - I haven't done a thorough analysis of your suggestion, but I would guess that it would be a little bit simpler. There would still be a significant amount of added complexity in the core, though. I'll finish the patch using the original logic first, and if you want, I can probably do another version to see how much the push model will differ. -- Tanu ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
[pulseaudio-discuss] [RFC] Allow read-only or non-existing sink input volume.
There are two known cases where read-only or non-existing sink input volume is relevant: passthrough streams and the planned volume sharing logic. Passthrough streams don't have volume at all, and the volume sharing logic requires read-only sink input volume. This commit is primarily working towards the volume sharing feature, but support for non-existing sink input volume is also added, because it is so closely related to read-only volume. Some unrelated refactoring in iface-stream.c creeped into this commit too (new function: stream_to_string()). This patch hasn't been tested properly yet, so don't commit this. I just want comments if you see something wrong in this patch. --- PROTOCOL|8 ++- src/modules/dbus/iface-stream.c | 120 ++- src/modules/module-stream-restore.c | 14 +++-- src/pulse/introspect.h |2 + src/pulsecore/cli-command.c |7 ++- src/pulsecore/cli-text.c| 20 -- src/pulsecore/protocol-native.c | 14 - src/pulsecore/sink-input.c | 29 +++- src/pulsecore/sink-input.h |3 + 9 files changed, 155 insertions(+), 62 deletions(-) diff --git a/PROTOCOL b/PROTOCOL index 3bd2894..c2bb209 100644 --- a/PROTOCOL +++ b/PROTOCOL @@ -203,7 +203,13 @@ new flag at end of CREATE_PLAYBACK_STREAM: ## v19, implemented by = 0.9.22 -New proplist field for sink input, source output introspection opcodes and at the end: +New flag at the end of sink input and source output introspection data: bool corked +## v20, implemented by = 1.0 + +Two new flags at the end of sink input introspection data: + +bool has_volume +bool read_only_volume diff --git a/src/modules/dbus/iface-stream.c b/src/modules/dbus/iface-stream.c index 681790b..a16c4ec 100644 --- a/src/modules/dbus/iface-stream.c +++ b/src/modules/dbus/iface-stream.c @@ -56,6 +56,9 @@ struct pa_dbusiface_stream { dbus_bool_t mute; pa_proplist *proplist; +pa_bool_t has_volume; +pa_bool_t read_only_volume; + pa_dbus_protocol *dbus_protocol; pa_subscription *subscription; pa_hook_slot *send_event_slot; @@ -189,6 +192,14 @@ static void handle_get_index(DBusConnection *conn, DBusMessage *msg, void *userd pa_dbus_send_basic_variant_reply(conn, msg, DBUS_TYPE_UINT32, idx); } +/* The returned string has to be freed with pa_xfree() by the caller. */ +static char *stream_to_string(pa_dbusiface_stream *s) { +if (s-type == STREAM_TYPE_PLAYBACK) +return pa_sprintf_malloc(Playback stream %u, (unsigned) s-sink_input-index); +else +return pa_sprintf_malloc(Record stream %u, (unsigned) s-source_output-index); +} + static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *userdata) { pa_dbusiface_stream *s = userdata; const char *driver = NULL; @@ -200,12 +211,11 @@ static void handle_get_driver(DBusConnection *conn, DBusMessage *msg, void *user driver = (s-type == STREAM_TYPE_PLAYBACK) ? s-sink_input-driver : s-source_output-driver; if (!driver) { -if (s-type == STREAM_TYPE_PLAYBACK) -pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, - Playback stream %u doesn't have a driver., s-sink_input-index); -else -pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, - Record stream %u doesn't have a driver., s-source_output-index); +char *str = stream_to_string(s); + +pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, %s doesn't have a driver., str); +pa_xfree(str); + return; } @@ -224,12 +234,11 @@ static void handle_get_owner_module(DBusConnection *conn, DBusMessage *msg, void owner_module = (s-type == STREAM_TYPE_PLAYBACK) ? s-sink_input-module : s-source_output-module; if (!owner_module) { -if (s-type == STREAM_TYPE_PLAYBACK) -pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, - Playback stream %u doesn't have an owner module., s-sink_input-index); -else -pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, - Record stream %u doesn't have an owner module., s-source_output-index); +char *str = stream_to_string(s); + +pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, %s doesn't have an owner module., str); +pa_xfree(str); + return; } @@ -250,12 +259,11 @@ static void handle_get_client(DBusConnection *conn, DBusMessage *msg, void *user client = (s-type == STREAM_TYPE_PLAYBACK) ? s-sink_input-client : s-source_output-client; if (!client) { -if (s-type == STREAM_TYPE_PLAYBACK) -pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, - Playback stream %u isn't associated to
Re: [pulseaudio-discuss] New feature in the works: volume sharing
'Twas brillig, and Tanu Kaskinen at 14/02/11 11:19 did gyre and gimble: On Sun, 2011-02-13 at 22:05 +0200, Colin Guthrie wrote: With this push based approach, you do loose some individual granularity, but the net volume of the underlying h/w should be the same as your approach. What granularity would I lose? I think your suggested logic would be quite equivalent to the one that I originally proposed. The concern I have with the approach outlined, is that it adds complexity to the core and I'm not 100% sure how far the chain can go (e.g. can you have a filter-sink1-filter-sink2-filter-sink3-hw-sink pipeline? - with a push model this is possible). It's possible with the pull model too - the filter sinks are always traversed recursively. About complexity - I haven't done a thorough analysis of your suggestion, but I would guess that it would be a little bit simpler. There would still be a significant amount of added complexity in the core, though. I'll finish the patch using the original logic first, and if you want, I can probably do another version to see how much the push model will differ. I don't really want to create extra work for you, I'm just genuinely unsure which would be considered a cleaner approach (or even if it really matters at all!!) Other opinions welcome :) Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Monday, February 14, 2011 08:58:39 AM Ng Oon-Ee wrote: On Sun, 2011-02-13 at 18:36 -0600, Gene Kodadek wrote: On Sunday, February 13, 2011 07:52:37 PM Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 13/02/11 19:19 did gyre and gimble: All right, here goes. Here are the steps I took: after starting Jack: 1) pulseaudio - 2) start-pulseaudio-x11 3) start-pulseaudio-kde 4) loaded jack modules (got an error message telling me they were already loaded) Here is the verbose output from that whole mess: I don't see any mention of the jack modules in the PA verbose output there. As no other sinks are available (udev-detect is run and detects your alsa cards, but as jackd is running and has the cards open already, it correctly reports the alsa devices as busy and thus doesn't create sinks/sources for them directly), the dummy output is automatically loaded but obviously as the name suggests, the sound effectively goes to /dev/null. Can you post the error messages you get from and the commands you use to load the jack modules (basically step 4 in your list)? That should help to debug further. For the benefit of yourself and Tanu, the screens in Phonon should look a little like the screenshots here: http://pulseaudio.org/wiki/KDE Col [gene@bruce ~]$ pulseaudio -L module-jack-sink -L module-jack-source E: pid.c: Daemon already running. E: main.c: pa_pid_file_create() failed. Rant warning You're an Arch Linux user. Does it not occur to you that 'daemon already running' means exactly what it says? ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss Okay, I went back and uninstalled Pulseaudio, wiped all the settings I changed, and then did everything all over again.. I'm sure I followed all of the steps correctly, but with exactly the same result: the only sound is from Jack-aware apps; nothing else has any output at all. After a reboot this is true whether Jack is running or not. There are no error messages; visually the apps seemed to be working as usual. But no output. The only device that shows up in System Settings - Multimedia - Phonon - Device Preferences is that dummy output device. Look, I know I sound like a confused noob here, but in four years of using Linux I've never really had any trouble with Linux sound, never tried to do any fancy configuring, and have never used pulseaudio. In short, I know very little about the Linux sound stack, and much of the available information online is confusing and contradictory. ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Problems trying to connecf HFP device
'Twas brillig, and Franz Glauber at 13/02/11 21:44 did gyre and gimble: Yeah, I thought so... I'm using 0.9.22 (latest ebuild on Gentoo). Do you think it's worth trying the git version? I don't think there are any BT specific changes in git master that are not also in stable-queue other that would affect this issue. That said, there have been bluez related changes, so I could be wrong It seems that, given the delay before the error, PA is waiting for some answer from the device, and that doesn't happen... Yeah that's what it looks like to me. Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Monday, February 14, 2011 08:58:39 AM Ng Oon-Ee wrote: On Sun, 2011-02-13 at 18:36 -0600, Gene Kodadek wrote: On Sunday, February 13, 2011 07:52:37 PM Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 13/02/11 19:19 did gyre and gimble: All right, here goes. Here are the steps I took: after starting Jack: 1) pulseaudio - 2) start-pulseaudio-x11 3) start-pulseaudio-kde 4) loaded jack modules (got an error message telling me they were already loaded) Here is the verbose output from that whole mess: I don't see any mention of the jack modules in the PA verbose output there. As no other sinks are available (udev-detect is run and detects your alsa cards, but as jackd is running and has the cards open already, it correctly reports the alsa devices as busy and thus doesn't create sinks/sources for them directly), the dummy output is automatically loaded but obviously as the name suggests, the sound effectively goes to /dev/null. Can you post the error messages you get from and the commands you use to load the jack modules (basically step 4 in your list)? That should help to debug further. For the benefit of yourself and Tanu, the screens in Phonon should look a little like the screenshots here: http://pulseaudio.org/wiki/KDE Col [gene@bruce ~]$ pulseaudio -L module-jack-sink -L module-jack-source E: pid.c: Daemon already running. E: main.c: pa_pid_file_create() failed. Rant warning You're an Arch Linux user. Does it not occur to you that 'daemon already running' means exactly what it says? ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss Another question: after I'd uninstalled all of the pulseaudio related software, ditched all of the config files, and reverted all my settings, something was still writing a .pulse and .pulse-cookie directory and file to my ~ directory. It caused some problems. Any idea what program might have been doing that? ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Build assembler errors on ARM OMAP3
On 13 February 2011 14:16, Colin Guthrie gm...@colin.guthr.ie wrote: 'Twas brillig, and Kurt Taylor at 07/02/11 18:52 did gyre and gimble: I am seeing the following when trying to build pulseaudio on an ARM-based Beagleboard (OMAP3): CC libpulsecore_1.0_la-svolume_arm.lo ../libtool: line 975: warning: setlocale: LC_MESSAGES: cannot change locale (en_GB.utf8) Hmm, not sure to be honest. Arun has been looking at Orc stuff to ultimately replace hand-written assembly but it's perhaps a bit early to think about that for ARM. Perhaps try speaking to the folk in git log for that file (basically poke Arun (Ford_Prefect) or Wim (wtay) on IRC :)) Thanks for the reply Colin. I did get it to build passing -Wa, -mimplicit-it=thumb as in the ubuntu debian rules, but really it should be ported so that it doesn't need that. I've added it to my todo list. Kurt Taylor (irc krtaylor) ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
'Twas brillig, and Gene Kodadek at 14/02/11 13:56 did gyre and gimble: Another question: after I'd uninstalled all of the pulseaudio related software, ditched all of the config files, and reverted all my settings, something was still writing a .pulse and .pulse-cookie directory and file to my ~ directory. It caused some problems. Any idea what program might have been doing that? I suspect that libpulse was still installed (many apps will be linked to it). It was probably responsible for that. Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
'Twas brillig, and Gene Kodadek at 14/02/11 13:36 did gyre and gimble: Okay, I went back and uninstalled Pulseaudio, wiped all the settings I changed, and then did everything all over again.. I'm sure I followed all of the steps correctly, but with exactly the same result: the only sound is from Jack-aware apps; nothing else has any output at all. After a reboot this is true whether Jack is running or not. There are no error messages; visually the apps seemed to be working as usual. But no output. The only device that shows up in System Settings - Multimedia - Phonon - Device Preferences is that dummy output device. Look, I know I sound like a confused noob here, but in four years of using Linux I've never really had any trouble with Linux sound, never tried to do any fancy configuring, and have never used pulseaudio. In short, I know very little about the Linux sound stack, and much of the available information online is confusing and contradictory. Did you see Jan's reply? I suspect you're still using the wrong command to load the jack modules into PA. You need to use pacmd or pactl, not pulseaudio itself. To repeat what Jan said, do not use this: pulseaudio -L module-jack-sink -L module-jack-source but rather use: pactl load-module module-jack-sink pactl load-module module-jack-source HTHs Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Build assembler errors on ARM OMAP3
On Mon, 2011-02-07 at 12:52 -0600, Kurt Taylor wrote: I am seeing the following when trying to build pulseaudio on an ARM-based Beagleboard (OMAP3): CC libpulsecore_1.0_la-svolume_arm.lo ../libtool: line 975: warning: setlocale: LC_MESSAGES: cannot change locale (en_GB.utf8) {standard input}: Assembler messages: {standard input}:82: Error: thumb conditional instruction should be in IT block -- `addcs r0,r8' {standard input}:83: Error: thumb conditional instruction should be in IT block -- `movcs r6,r0' {standard input}:98: Error: thumb conditional instruction should be in IT block -- `addcs r0,r8' {standard input}:99: Error: thumb conditional instruction should be in IT block -- `movcs r6,r0' {standard input}:119: Error: thumb conditional instruction should be in IT block -- `addcs r0,r8' {standard input}:120: Error: thumb conditional instruction should be in IT block -- `movcs r6,r0' I am using the normal build (bootstrap.sh, configure, make) on Linaro ALIP on the Beagleboard. The build worked fine on a Pandaboard with Ubuntu 10.10. It looks like something is different and not being detected via bootstrap/configure on ALIP. I believe configure has identified the architecture correctly. Also, I have searched and seen commits in the pulseaudio/ubuntu maillist archive for adding -Wa, -mimplicit-it=thumb. I have added this to CFLAGS without success. Any thoughts on what else I could try? What CFLAGS are you using? This should only turn up if you're compiling that assembly in Thumb-2 mode. I'm not sure if it would actually be desirable to compile in Thumb-2 mode for the OMAP3, but the correct fix for this would probably be to add an ite cs before the addcs in svolume_arm.c. Could you test this out (or let me know if you'd like a patch that does this)? -- Arun ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Monday, February 14, 2011 02:36:53 PM Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 14/02/11 13:36 did gyre and gimble: Okay, I went back and uninstalled Pulseaudio, wiped all the settings I changed, and then did everything all over again.. I'm sure I followed all of the steps correctly, but with exactly the same result: the only sound is from Jack-aware apps; nothing else has any output at all. After a reboot this is true whether Jack is running or not. There are no error messages; visually the apps seemed to be working as usual. But no output. The only device that shows up in System Settings - Multimedia - Phonon - Device Preferences is that dummy output device. Look, I know I sound like a confused noob here, but in four years of using Linux I've never really had any trouble with Linux sound, never tried to do any fancy configuring, and have never used pulseaudio. In short, I know very little about the Linux sound stack, and much of the available information online is confusing and contradictory. Did you see Jan's reply? I suspect you're still using the wrong command to load the jack modules into PA. You need to use pacmd or pactl, not pulseaudio itself. To repeat what Jan said, do not use this: pulseaudio -L module-jack-sink -L module-jack-source but rather use: pactl load-module module-jack-sink pactl load-module module-jack-source HTHs Col Ladies and gentlemen, I have sound!!! Now I'm trying to figure out how to automate this... ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Mon, Feb 14, 2011 at 4:43 PM, Gene Kodadek gkoda...@gmail.com wrote: Ladies and gentlemen, I have sound!!! Now I'm trying to figure out how to automate this... Either alter /etc/pulse/default.pa or copy it to ~/.pulse/default.pa and alter it there. ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
'Twas brillig, and Gene Kodadek at 14/02/11 16:21 did gyre and gimble: The result of this setup is that I have sound only when Jack is running, which is not exactly what I had in mind. What I want to achieve here is to have Pulseaudio off under ordinary circumstances, and only start when Jack is running. Really what should happen is that PA should run all the time. Initially jack is not running as the machine is presumably not a sole-purpose audio-dev machine seeing as you mention the only when jack is running case which implies it sometimes does not run. This means module-udev-detect should detect and load module-alsa-card for you and subsequently give you direct access to ALSA sinks/sources. When Jack runs, it should request access to the devices via dbus (PA and Jack cooperate an 'device reservation protocol' that allows jack to ask for the device at which point PA will grant access). At this point a special module (git master only) called module-jackdbus-detect will detect that jack is running and automatically load module-jack-sink and friends for you. Sadly this isn't 100% working just yet. PA suspends the alsa sinks when it hands over to Jack rather than unloading them totally. This means active streams (and even new ones) are not failed over to the new jack sinks. This isn't ideal. More work is needed in the various PA modules and core to make this 100% smooth. All the best Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Monday, February 14, 2011 04:44:52 PM Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 14/02/11 16:21 did gyre and gimble: The result of this setup is that I have sound only when Jack is running, which is not exactly what I had in mind. What I want to achieve here is to have Pulseaudio off under ordinary circumstances, and only start when Jack is running. Really what should happen is that PA should run all the time. Initially jack is not running as the machine is presumably not a sole-purpose audio-dev machine seeing as you mention the only when jack is running case which implies it sometimes does not run. This means module-udev-detect should detect and load module-alsa-card for you and subsequently give you direct access to ALSA sinks/sources. When Jack runs, it should request access to the devices via dbus (PA and Jack cooperate an 'device reservation protocol' that allows jack to ask for the device at which point PA will grant access). At this point a special module (git master only) called module-jackdbus-detect will detect that jack is running and automatically load module-jack-sink and friends for you. Sadly this isn't 100% working just yet. PA suspends the alsa sinks when it hands over to Jack rather than unloading them totally. This means active streams (and even new ones) are not failed over to the new jack sinks. This isn't ideal. More work is needed in the various PA modules and core to make this 100% smooth. All the best Col I would consider PA running all the time to be an acceptable solution except for one thing: as it sits right now, I only have sound when Jack is running. ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
'Twas brillig, and Gene Kodadek at 14/02/11 16:54 did gyre and gimble: I would consider PA running all the time to be an acceptable solution except for one thing: as it sits right now, I only have sound when Jack is running. Well as your default.pa does not even use module-udev-detect, then it's unsurprising that you don't have sound when jack isn't running. You've specifically told PA to only load the jack sink modules. This is your configuration, so you are free to configure it as needed. You could just run e.g.: pactl load-module module-alsa-card device_id=0 (or something similar - I can't remember the exact arguments) and you'll get direct alsa modules, but you will of course have to unload those modules and load the jack ones when you switch to using jack. For a fairly static setup (e.g. no hotplug support) scripting this should be pretty trivial with a few pactl or pacmd commands (i.e. pactl unload-module $MID (where $MID is the module id you want to unload) would be used to unload jack modules then pactl load-module module-alsa-card device_id=0 would be used to load the alsa modules. Then you have to reverse the process (unload the alsa-card module and load the jack modules when you want to switch the other way. This will ultimately be fully automated, but for now you are on your own. I think various scripts for achieving basically this have been posted in the past however. Personally what I would do is as follows: 1. Do not run jack at boot. 2. Let PA run with the upstream default.pa (no modifications). 3. When you want to run jack, do something like: pacmd set-card-profile 0 off (assuming the 0 card is the one you want to change - check pacmd list-cards for details on the index to use). 4. pacmd load-module module-jack-sink (and source) Then when you stop running jack run somehting like: 1. pacmd unload-module $JMID (where $JMID is the jack module id). This step may not be needed as the modules may automatically unload when jackd dies. 2. pacmd set-card-profile 0 $WHATEVER (where $WHATEVER is the card profile (shown in pacmd list-cards) you want to use. This setup can probably be automated in jack startup and shutdown scripts (not really sure) and means you get full hotplug support for USB devices etc. HTHs Col Col -- Colin Guthrie gmane(at)colin.guthr.ie http://colin.guthr.ie/ Day Job: Tribalogic Limited [http://www.tribalogic.net/] Open Source: Mageia Contributor [http://www.mageia.org/] PulseAudio Hacker [http://www.pulseaudio.org/] Trac Hacker [http://trac.edgewall.org/] ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Monday, February 14, 2011 06:04:25 PM Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 14/02/11 16:54 did gyre and gimble: I would consider PA running all the time to be an acceptable solution except for one thing: as it sits right now, I only have sound when Jack is running. Well as your default.pa does not even use module-udev-detect, then it's unsurprising that you don't have sound when jack isn't running. You've specifically told PA to only load the jack sink modules. This is your configuration, so you are free to configure it as needed. You could just run e.g.: pactl load-module module-alsa-card device_id=0 (or something similar - I can't remember the exact arguments) and you'll get direct alsa modules, but you will of course have to unload those modules and load the jack ones when you switch to using jack. For a fairly static setup (e.g. no hotplug support) scripting this should be pretty trivial with a few pactl or pacmd commands (i.e. pactl unload-module $MID (where $MID is the module id you want to unload) would be used to unload jack modules then pactl load-module module-alsa-card device_id=0 would be used to load the alsa modules. Then you have to reverse the process (unload the alsa-card module and load the jack modules when you want to switch the other way. This will ultimately be fully automated, but for now you are on your own. I think various scripts for achieving basically this have been posted in the past however. Personally what I would do is as follows: 1. Do not run jack at boot. 2. Let PA run with the upstream default.pa (no modifications). 3. When you want to run jack, do something like: pacmd set-card-profile 0 off (assuming the 0 card is the one you want to change - check pacmd list-cards for details on the index to use). 4. pacmd load-module module-jack-sink (and source) Then when you stop running jack run somehting like: 1. pacmd unload-module $JMID (where $JMID is the jack module id). This step may not be needed as the modules may automatically unload when jackd dies. 2. pacmd set-card-profile 0 $WHATEVER (where $WHATEVER is the card profile (shown in pacmd list-cards) you want to use. This setup can probably be automated in jack startup and shutdown scripts (not really sure) and means you get full hotplug support for USB devices etc. HTHs Col Col There's a problem with that. With the default /etc/pulse/default.pa I have no sound at login. I can only get sound by loading the jack modules and running Jack. System Settings - Multimedia - Phonon - Device Preference only shows the dummy output and the Jack sink, which cries out to me that there's still something wrong with my PulseAudio configuration. ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] Trying to get Pukseaudio playing nice with KDE 4.6 on Arch Linux
On Mon, 2011-02-14 at 19:39 +, Colin Guthrie wrote: 'Twas brillig, and Gene Kodadek at 14/02/11 19:10 did gyre and gimble: There's a problem with that. With the default /etc/pulse/default.pa I have no sound at login. I can only get sound by loading the jack modules and running Jack. System Settings - Multimedia - Phonon - Device Preference only shows the dummy output and the Jack sink, which cries out to me that there's still something wrong with my PulseAudio configuration. Does jack run at login? If so this is expected. As I said in my reply, I'd recommend NOT running jack at login. If this is not the problem then we'll need to look deeper (basically provide pulseaudio - output while jackd is not running with the upstream default.pa) Col I have some fairly simple scripts (pulse-withjack and pulse-withoutjack) which I use to load up jack when needed. Here's the general logic. 1. My default.pa uses module-udev-detect. 2. When I want Jack, I do the following (scripted) a. start jack b. load-module module-jack-sink/source 3. When I want to stop Jack, I do the following (scripted) a. find the module-jack-sink/source IDs b. unload-module them c. stop jack This is of course with jack2 (with the previously-mentioned dbus-based suspend of sound). If with jack1, you'd have to add logic to unload the alsa modules before starting jack and reloading them after stopping jack. ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss
Re: [pulseaudio-discuss] New feature in the works: volume sharing
On 2011-02-14 12:45, Colin Guthrie wrote: 'Twas brillig, and Tanu Kaskinen at 14/02/11 11:19 did gyre and gimble: On Sun, 2011-02-13 at 22:05 +0200, Colin Guthrie wrote: With this push based approach, you do loose some individual granularity, but the net volume of the underlying h/w should be the same as your approach. What granularity would I lose? I think your suggested logic would be quite equivalent to the one that I originally proposed. The concern I have with the approach outlined, is that it adds complexity to the core and I'm not 100% sure how far the chain can go (e.g. can you have a filter-sink1-filter-sink2-filter-sink3-hw-sink pipeline? - with a push model this is possible). It's possible with the pull model too - the filter sinks are always traversed recursively. About complexity - I haven't done a thorough analysis of your suggestion, but I would guess that it would be a little bit simpler. There would still be a significant amount of added complexity in the core, though. I'll finish the patch using the original logic first, and if you want, I can probably do another version to see how much the push model will differ. I don't really want to create extra work for you, I'm just genuinely unsure which would be considered a cleaner approach (or even if it really matters at all!!) Other opinions welcome :) I have a question: how about the volume store/restore module? Will it store and restore the outermost sink's volume, the innermost one, or both? Another thing is the pick-up of volume/mute changes in the driver - at least that's done on the ALSA side. Will that then be pushed through in the other direction somehow, or...? Just trying to make sure you haven't missed anything :-) -- David Henningsson, Canonical Ltd. http://launchpad.net/~diwic ___ pulseaudio-discuss mailing list pulseaudio-discuss@mail.0pointer.de https://tango.0pointer.de/mailman/listinfo/pulseaudio-discuss