Index | Thread | Search

From:
Alexandre Ratchov <alex@caoua.org>
Subject:
Re: aucat: Add generic channel mapping in place of -j and -c options.
To:
Jan Stary <hans@stare.cz>
Cc:
tech@openbsd.org
Date:
Mon, 18 Mar 2024 15:36:51 +0100

Download raw body.

Thread
On Mon, Mar 18, 2024 at 01:30:51PM +0100, Jan Stary wrote:
> I find the swapped order of A/B in -m A/B for -o files
> a bit confusing; for example, the manpage example
> 
> 	aucat -n -i stereo.wav -c 1
> 		-m 0:0/0:0 -o left.wav
> 		-m 0:0/1:1 -o right.wav
> 
> creates the right.wav having the (only) 0:0 channel
> take its data *from* the 1:1 channel of -i stereo.wav;
> 
> It is one of the two possibilities of course,
> but having the meaning of -m A/B uniform of both -i and -o files
> would be slightly less confusing imho.
> 

Well, it's uniform: file channels first, followed by device channels.

But I get your point: my eyes are also used to see the producer
followed by the consumer. Indeed, producer and consumer get swapped:
the file is the producer in the playback case, and consumer in the
recording case).

> > +.It Fl m Ar min : Ns Ar max Ns / Ns Ar min : Ns Ar max
> > +Map the given range of file channels into the given range of
> > +device channels.
> 
> If it stays swapped as in the current diff,
> the manpage should perhaps say so explicitly.
> 

The man page is correct (file first, device second).

But they look swapped if you think in terms of producer vs consumer.

> Also, with -n, there is no "device", so no "device channels".
> Would it be clearer to talk about "input channels" and "output channels"
> instead in the Fl m portion of the manpage?
> 

Yeah, we should explain what -n does: FWIW, it creates an internal
pseudo-device that records what it plays. So the concept of device
channels remains. Or should we say "bus" instead of device?

But that's for another diff