Re: [Alsa-user] Sending all audio over socket
Brought to you by:
perex
|
From: Guru P. <gur...@bu...> - 2015-05-07 12:25:39
|
I had some luck with the named pipe setup. I was able to set up
.asoundrc to write to a named pipe in /tmp and then send this data
over a socket and play it on another machine.
However, all (audio) applications freeze until my program (which reads
from the pipe) begins to run. This is expected behaviour of named
pipes.
I believe I can solve this by modifying the PCM 'default' dynamically.
That way, I can modify the PCM at the start of my program to use my
custom .asoundrc.
Is it possible to:
1) Modify PCM 'default' on the fly?
2) Re-initialize ALSA with a new .asoundrc without
rebooting/restarting the desktop manager?
@Anders:
I tried that approach already with no luck. For some reason when I
include snd-aloop to my modules, aplay -L does not show any of the
loopback devices.
On Thu, May 7, 2015 at 3:01 AM, Anders Genell <and...@gm...> wrote:
>
>> 7 maj 2015 kl. 05:23 skrev Guru Prasad <gur...@bu...>:
>>
>> Could you give me an example of how I can ask the PCM file plugin to
>> write to a named pipe?
>> Should i create this manually or can I somehow do this via the PCM
>> file plugin itself by using the '|' character?
>>
>> Also, don't named pipes block until there is a reader? Given that I've
>> only been able to do this via .asoundrc (and not via the
>> snd_pcm_file_open), I'm not sure how the blocking behaviour would
>> interact with ALSA. Would only my file plugin PCM definition block
>> while others continue?
>>
>> Regardless, thank you for the suggestion. I will try this out meanwhile.
>>
>> Regards
>> Guru
>
> Maybe this could be a starting point?
>
> http://plasmasturm.org/log/soundserverhack/
>
> Regards,
> /Anders
>
>
|