[mythtv-users] YAAQ (Yet Another ALSA Question)

Stephen Tait tait at digitallaw.co.uk
Tue Jun 29 08:30:41 EDT 2004


Wow, thanks for the detailed reply Michael!


>>>On Sun, Jun 27, 2004 at 05:44:13PM +0100, Stephen Tait wrote:
>>> > OK, I know the Right Way to get Myth to use native ALSA is to swap 
>>> /dev/dsp
>>> > or /dev/sound/dsp for alsa:whatever, which is all fine...
>>> >
>>> > But what about the mixer? I'm currently using /dev/sound/mixer (OSS
>>> > emulation provided by ALSA), but can't find anywhere what to put in it.
>>> > Helpful replies will be awarded 10,000 points and a bowl of 
>>> strawberry jam!
>>>
>>>I left the default as it was and it seemed to just work for me.. ?!
>>>
>>>I'm now using SPDIF out where the volume control in Myth doesn't do
>>>anything any way.
>>
>>
>>I know it's very easy to leave it at the default; I just want to be able 
>>to excise OSS emulation mode completely so I don't need alsa-oss or my 
>>oss USE flag any more (to get myself ready for 2.6 and cruft removal) - 
>>obviously, if I did that at the moment, I'd get no mixer controls. The 
>>only apps this machine ever uses are Myth, Xine and mPlayer, all of which 
>>are compiled with native ALSA.
>>
>>Can I just chuck alsamixer in there or what?
>
>Unfortunately, it's not that simple.  alsamixer is a program (software 
>mixer) used to send instructions to the ALSA driver requesting it send 
>instructions to the sound card's hardware mixer.  ALSA allows programs to 
>make these requests by using a control device (ctl-device).
>
>Myth requires specifying a mixer device (not a program/software mixer); 
>therefore, you would need to specify your ALSA control device--which would 
>be something like "ctl.default" (if you haven't defined any in your 
>.asoundrc, or, if you have, whatever you specified in your 
>.asoundrc).  Extrapolating based on the syntax for specifying an ALSA 
>sound device, Myth would use a string like "ALSA:ctl.default".

Wow - you've pointed out how little I know about ALSA! I shall give the 
docs a peruse (obviously, googling for "alsa" and "mixer" and the like 
brought up rather alot of irrelevant pages); I had never even heard of ALSA 
control functions before. Since I'm using an Audigy, I guess this will be 
pretty well documented (AFAIK, the emu10k1 cards are the only ones 
currently available that have a hardware mixer supported under Linux).

>However, quickly perusing mythtv/libs/libmyth/volumecontrol.cpp, it seems 
>that Myth only supports volume changing through OSS (i.e. 
>SOUND_MIXER_VOLUME, SOUND_MIXER_PCM instead of ALSA's Master and PCM 
>controls, respectively).  Therefore, Myth does not yet include native ALSA 
>control device support.  (So how big is your itch, anyway?)

My itch isn't that huge; but you know how irritating it is when you 
(supposedly) technically don't need a swathe of software, but can't get rid 
of it for niggly reasons (*cough*IE*cough*). It's just a bit of a bummer; 
aside from the ancillary benefits, there doesn't seem much point in going 
the whole hog on ALSA until Myth gets ALSA volume-control support; not an 
issue for those using SPDIF passthrough (AFAICT the prime reason for using 
ALSA for most people) obviously. Does anyone know if this is in planning 
for Myth at all?


>On the bright side, however, ALSA's OSS emulation layer does a wonderful 
>job of mapping OSS mixer controls to ALSA's native mixer 
>controls--especially when you realize how complicated the mapping is (it 
>is not a simple one-to-one mapping).

Well, I don't know how complicated the mapping is (IANAP), but (after 
suffering plenty of other apps that don't handle sound very well) I fully 
appreciate the excellent audio support in Myth.


>HTH.

Yup - at least I (think I) now know the right questions to ask! Your prize 
is attached.

Thanks!

/me bows down in "We're not worthy" stylée

>Mike
>_______________________________________________
>mythtv-users mailing list
>mythtv-users at mythtv.org
>http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
-------------- next part --------------
A non-text attachment was scrubbed...
Name: your_prize.jpg
Type: image/jpeg
Size: 19191 bytes
Desc: not available
Url : http://mythtv.org/pipermail/mythtv-users/attachments/20040629/dd1cce91/your_prize-0001.jpg


More information about the mythtv-users mailing list