Re: [Alsa-user] Independent Simultaneous playback over 5 channels
Allen Kennedy wrote: On 10/25/07, Clemens Ladisch [EMAIL PROTECTED] wrote: Try this: pcm.channel { @args [ CHANNEL ] @args.CHANNEL { type integer } type plug slave.pcm { type dshare ipc_key 220057 # some random but unique number slave.pcm hw:0# the output device slave.channels 6 bindings { 0 $CHANNEL } } } ... One issue though, it appears as though your solution would only route a single channel of the input wave file. The plug plugin should automatically downmix multichannel data before sending it to the dshare plugin. What is the output of aplay -v -D channel:0 somestereo.wav? slave.pcm channel: +$CHANNEL # can't figure out how to concat That line would have to be written like this: slave.pcm { @func concat strings [ channel: $CHANNEL ] } Regards, Clemens - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now http://get.splunk.com/ ___ Alsa-user mailing list Alsa-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-user
Re: [Alsa-user] Independent Simultaneous playback over 5 channels
Allen Kennedy wrote: I'm trying to get an asound.conf file set up that will allow me to play 5 different wav files over separate channels simultaneously, with a command like this: #aplay -D channel1 1.wav aplay -D channel2 2.wav aplay -D channel3 3.wav aplay -D channel4 4.wav aplay -D channel5 5.wav Try this: pcm.channel { @args [ CHANNEL ] @args.CHANNEL { type integer } type plug slave.pcm { type dshare ipc_key 220057 # some random but unique number slave.pcm hw:0# the output device slave.channels 6 bindings { 0 $CHANNEL } } } Then you can use devices channel:0 through channel:5. HTH Clemens - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now http://get.splunk.com/ ___ Alsa-user mailing list Alsa-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-user
Re: [Alsa-user] Independent Simultaneous playback over 5 channels
On 10/25/07, Clemens Ladisch [EMAIL PROTECTED] wrote: Allen Kennedy wrote: I'm trying to get an asound.conf file set up that will allow me to play 5 different wav files over separate channels simultaneously, with a command like this: #aplay -D channel1 1.wav aplay -D channel2 2.wav aplay -D channel3 3.wav aplay -D channel4 4.wav aplay -D channel5 5.wav Try this: pcm.channel { @args [ CHANNEL ] @args.CHANNEL { type integer } type plug slave.pcm { type dshare ipc_key 220057 # some random but unique number slave.pcm hw:0# the output device slave.channels 6 bindings { 0 $CHANNEL } } } Then you can use devices channel:0 through channel:5. HTH Clemens I had just gotten it to work using a dmix when your e-mail came in. I like your way better, much cleaner and more elegant. Thanks One issue though, it appears as though your solution would only route a single channel of the input wave file. adding in more bindings still only caused it to route 1 channel of the input audio. I guess I still need a route to get all the channels of the .wav to funnel together into the output channel. instead of writing 5 sepereate routes, I tried to use the args, but couldn't get the syntax correct, any ideas? It's unfortunate that the alsa documentation doesn't explain well the syntax for the config files.. pcm.ch { @args [ CHANNEL ] @args.CHANNEL { type string } type route slave.pcm channel: +$CHANNEL # can't figure out how to concat ttable.0.0 1 ttable.1.0 1 ttable.2.0 1 ttable.3.0 1 ttable.4.0 1 ttable.5.0 1 } I keep getting an error from aplay about the config syntax. I tried reading through the code to see how the parse works, but I gave up after 20 minutes. - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now http://get.splunk.com/___ Alsa-user mailing list Alsa-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-user
[Alsa-user] Independent Simultaneous playback over 5 channels
Hello, I'm trying to get an asound.conf file set up that will allow me to play 5 different wav files over separate channels simultaneously, with a command like this: #aplay -D channel1 1.wav aplay -D channel2 2.wav aplay -D channel3 3.wav aplay -D channel4 4.wav aplay -D channel5 5.wav My first attempt was a file full of these: ...snip... pcm.channel3 { type route slave.pcm default slave.channels 6 #map all output sound strictly to channel 2 ttable.0.2 1 ttable.1.2 1 ttable.2.2 1 ttable.3.2 1 ttable.4.2 1 ttable.5.2 1 } ... snip ... but this only works for channels 1 and 2 doing an aplay -v -D channel1 1.wav, I see why, my stream gets routed through a 2 channel plug conversion: (edited for brevity) Route conversion PCM Transformation table: 0 - none 1 - none 2 - 0 + 1 + 2 + 3 + 4 + 5 Its setup is: channels : 1 rate : 16000 Slave: Plug PCM: Route conversion PCM (sformat=U8) Transformation table: 0 - 0 1 - 1 Its setup is: channels : 6 rate : 16000 Slave: Rate conversion PCM (48000, sformat=S16_LE) Its setup is: channels : 2 rate : 16000 Slave: Direct Stream Mixing PCM Its setup is: channels : 2 rate : 48000 Hardware PCM card 0 'Intel 82801DB-ICH4' device 0 subdevice 0 Its setup is: channels : 2 How can I route directly to the Slave: Rate conversion PCM (48000, sformat=S16_LE)? bypassing that 6 - 2 channel conversion. or conversely how do I tell the plug to keep all 6 channels? also my alsamixer is set to do no down converting, and I do have output from a 6 channel test wave file played through -D surround51 and Speaker-test will only give me sound on all 6 channels IF I specify -c 6 -D surround51 with no -D it indicates it plays to all the channels, but I only get sound out of channels 0 and 1. I've also tried creating custom mixer setups, and custom rate converters, dshare's and shares. I'm at a total loss. thanks, -Allen - This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now http://get.splunk.com/___ Alsa-user mailing list Alsa-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/alsa-user