On Tue, 3 Feb 2004, Fons Adriaensen wrote:
On Tue, Feb 03, 2004 Kai Vehmanen wrote:
-a:2 -i t2.wav -ea:200 \
-a:5 -i t5.wav -erc:1,5 -ea:200 \
-a:2,5 -f:32,10,44100 -o alsa
Shouldn't there be a
'-erc:1,2' on the t2.wav chain (it should go to
ouput 2) ?
Yes, error in my example.
The
'-ea:200' at the end of chains 2 and 5 helps to keep the volume
constant. This is ugly, but unfortunately something I cannot fix at this
Why is
this necessary ? Nothing should be mixed... unless alsa inputs
2 and 5 are also mixed in. If this is so, can it be prevented ?
Ecasound has to combine chains 2 and 5. Former has 1 channel of audio, the
latter 5 channels. Now the problem is two-fold: first, Ecasound does not
know that only ch5 of chain 5 has audio and others are in fact silent.
Secondly, Ecasound mixes chains by doing channel-by-channel add+divide. So
without the '-ea:200', volume of channels 1 and 5 in the stream going to
the ALSA device would be halved.
It's ugly, but ensures backwards compability.
> -a:t2 -i t2.wav -erc:1,2 -f:32,10,44100 -o
alsa,hw:0
> -a:t5 -i t5.wav -erc:1,5 -f:32,10,44100 -o alsa,hw:0
[...]
-a:t1
-f:32,14,44100 -i alsa,hw:0 -f:32,1,44100 -o t1.wav
-a:t6 -f:32,14,44100 -i alsa,hw:0 -erc:6,1 -f:32,1,44100 -o t6.wav
I kind of like
this 'per chain' way of writing things.
Unfortunately the above examples are not quite correct as '-a:t2 -o
alsa,hw:0 -a:t5 -o alsa,hw:0' is not equivalent to '-a:t2,t5 -o
alsa,hw:0'. The former creates two devices (which will fail in this case
as you can open an ALSA hw-device just once), while the latter creates one
ALSA device and connects it to two chains).
For this reason, I like to write Ecasound setups with one input/output per
line. This helps to write valid setups.
Would adding '-erc:1,1' to the a:t1 chain hurt
in any way ? It would be
nice to have a uniform syntax.
It wouldn't change the processing result in anyway, so it's ok. But it
does add to CPU usage.
--
http://www.eca.cx
Audio software for Linux!