From alsa-devel-owner@alsa.jcu.cz  Sun Feb 28 20:51:22 1999
Received: from mascarat.dragonet.es (dragonet.es [194.179.92.6])
	by marvin.jcu.cz (8.9.1a/8.9.1) with ESMTP id UAA01729
	for <alsa-devel@alsa.jcu.cz>; Sun, 28 Feb 1999 20:48:54 +0100
Received: from Trantor.usr.dragonet.es (root@dinamic1-4.drago.net [195.76.196.4]) by mascarat.dragonet.es (8.8.7/8.7.3) with ESMTP id UAA27848 for <alsa-devel@alsa.jcu.cz>; Sun, 28 Feb 1999 20:41:20 +0100
Received: from Trantor.dragonet.es (4422 bytes) by Trantor.usr.dragonet.es
	via smail with P:bsmtp/R:smart_host/T:smtp
	(sender: <f.andres@usa.net>) 
	id <m10HCCR-000Y2YC@Trantor.usr.dragonet.es>
	for <alsa-devel@alsa.jcu.cz>; Sun, 28 Feb 1999 20:48:27 +0100 (CET)
	(Smail-3.2.0.101 1997-Dec-17 #2 built 1998-Jul-16)
Received: from localhost (really [127.0.0.1]) by Trantor.Trnet.org
	via in.smtpd with esmtp
	id <m10HYbX-0008ZdC@Trantor.Trnet.org> (Debian Smail3.2.0.101)
	for <alsa-devel@alsa.jcu.cz>; Mon, 1 Mar 1999 20:43:51 +0100 (CET) 
Date: Mon, 1 Mar 1999 19:43:51 +0000 (GMT)
From: Paco Andres Verdu <f.andres@usa.net>
To: alsa-devel@alsa.jcu.cz
Subject: Re: Another mixer change proposal
In-Reply-To: <36D81DA4.955CEAEA@racine.ra.it>
Message-ID: <Pine.LNX.3.96.990228130341.418A-100000@Trantor.Trnet.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=iso-8859-1
Content-Transfer-Encoding: 8BIT
Reply-To: alsa-devel@alsa.jcu.cz
Sender: alsa-devel-owner@alsa.jcu.cz
Precedence: list

On Sat, 27 Feb 1999, Abramo Bagnara wrote:

> Jaroslav Kysela wrote:
> 
> > 2) Would be also the mixer to control PCM voice volumes?
> >    - I don't think it. The mixer would control only the output volumes.
> >      We must probably extend PCM for balance (or better PCM voice
> >      volume setup). This volume setup wouldn't be only left and right, but
> >      probably more universal to satisfy all things.
> 
> The possible manipulation of PCM output are potentially infinite:
> - 3D
> - Balancing
> - Routing
> - Bass
> - Treble
> - Equalizer
> ...
> 
> We can't choose now which we will introduce at kernel level.
> I think that the better way is to give the possibility to loaded modules to add
> PCM manipulation and contemporary to add mixer control or switch in a dynamic
> way.

  For soundcards based on Dream's sam9407 dsp (Guillemot Maxisound series,
Hoontech ST series, Terratec EWS, etc) a more universal volume setup
would be helpful ( it has four speaker volumes), but Abramo's proposal would
be better suited since these soundcards have the ability to dynamically
reconfigure to add/remove devices (i.e .- none/2/3/4 bands equalizer, 2/4
speaker output, add/remove devices (surround, reverb, echo, ...), etc), the
possibility of adding/removing mixer controls, and PCM manipulation would
allow to support these features on the kernel.

  Since these features can be applied to any of the soundcard's channels
(MIDI syntetiser, static wave (voices), input from the codec and PCM
(dynamic) wave), May be these effects could be implemented as
dynamically loaded sound processing modules (mixer channels) whose
input/output could be routed (with routing switches) to another channels
(the main sound output for instance).

  That way an application should be able to say: turn on the equalizer
switch (that would make a 2/3/4 bands switch available to the application),
set the switch to two bands (that would make four sliders avaiable, two for
gain and two for center freq. ), connect it's input to the codec's output
and it's output to the main output.

  The changes needed to the actual ALSA mixer structure should be minimum,
mainly to allow for dynamic registering/unregistering of devices (channels)
and sliders.

  To summarize it : A mixer is composed of switches (routing and nonrouting
ones) and channels (devices), which in turn are composed of switches and
sliders. The number of of channels, switches and sliders should be
dynamically variable after having registered the device,  maybe an
'update_mixer' function ?.

  That way a four speaker volume control could be represented by : a switch
that selects between 2/4 speakers, and a set of 2/4 (depending on the switch's
position) sliders to control the volume on each speaker.

  I think that the volume settings of each device should be done on the
mixer (as they are done in real world) rather than in the device itself, buy
maybe a pointer on each device, whose volume could be set, to it's
associated mixer channel would be helpful.

  The idea I'm trying to model is that of an HI-FI Rack Amplifier's, with
switches to control the routing of the inputs (enabling or disabling
devices like the bass/treble devices) to the output, and a set of sliders to
control the behavior of these devices (i.e. .- the bass gain slider). I
expect not to have failed to explain this idea.
 

                              Saludos

-----------------------------------------------------------------------------
Paco Andrs Verd                                          f.andres@usa.net
Alicante (Spain)                                              



