Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jan 2012 20:38:28 +0400
From:      Ruslan Bukin <br@bsdpad.com>
To:        Alexander Motin <mav@FreeBSD.org>
Cc:        freebsd-multimedia@FreeBSD.org
Subject:   Re: multi-mono-channel sound card
Message-ID:  <20120122163828.GA18783@jail.io>
In-Reply-To: <4F1ADDC8.90104@FreeBSD.org>
References:  <mailpost.1327157687.2711952.14470.mailing.freebsd.multimedia@FreeBSD.cs.nctu.edu.tw> <4F1ADDC8.90104@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi,

On Sat, Jan 21, 2012 at 05:46:16PM +0200, Alexander Motin wrote:
> On 01/21/12 16:12, Ruslan Bukin wrote:
> >My multichannel sound card (RME HDSPe AIO) is support
> >SND_FORMAT(AFMT_S32_LE, 1, 0) only.
> >
> >I call pcm_addchan(..), which triggers chan_init(..,*snd_dbuf,..)
> >Addr of snd_dbuf I write to card in slot N.
> >In result I have /dev/dsp0.pN devices (one device per each mono channel)
> >
> >Works perfectly, sounds great, but in mono mode.
> >
> >I'm interested, what is the right way to implement
> >stereo pair of channels per one device file like in OSS?
> 
> pcm_addchan() registers set of equal playback/record channels that
> are supposed to be mixed into the same signal. It is hardware
> equivalent of vchans. It has nothing common with multiple speakers.
> 
> Multichannel audio is always multiplexed and AFAIk there is no
> demultiplexing in sound(4). Sound(4) can upmix/downmix channels,
> change their order, format, rate, but not demultiplex.
> 
> I see only two ways:
>  - implement demultiplexing in driver -- that is not easy, but I
> believe it should be possible;
>  - export each input/output connector as separate PCM device and let
> some user level software to do demultiplexing -- that is easy and
> that is what snd_emu10kx does. snd_emu10kx(4) recommends to use
> pulseaudio for demultiplexing.

Thanks. I have implemented demultiplexing. Works great.
I will release the driver soon.

-Ruslan

> 
> -- 
> Alexander Motin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120122163828.GA18783>