From: thomas schorpp <t.schorpp@gmx.de>
To: alsa-devel@lists.sourceforge.net
Subject: Re: softvol plugin
Date: Sun, 20 Feb 2005 22:03:15 +0100 [thread overview]
Message-ID: <4218FB13.2020507@gmx.de> (raw)
In-Reply-To: <1108847548.10705.43.camel@krustophenia.net>
Lee Revell wrote:
> On Sat, 2005-02-19 at 22:08 +0100, thomas schorpp wrote:
>
>>sorry, i cant get a pcm master slider on any mixer.
mmh, ok, im satisfied with 4 dxs channel sliders and no pcm master.
no more practical need for pcm master for me.
and xmmms has the softvol in, yet.
BTW, i got a CMedia 8738 - 5.1 CH pci, if someone wants testing, drop me
a mail.
> OK, that's a separate issue (a bug). All I was saying is that it's not
> a reason to put anything in the kernel.
no bug. all right. thx.
.. i tried to give seperate names for the 4 DXS mixer ctls:
static int snd_via8233_init_misc(via82xx_t *chip, int dev)
{
int i, err, caps;
unsigned char val;
caps = chip->chip_type == TYPE_VIA8233A ? 1 : 2;
for (i = 0; i < caps; i++) {
snd_via8233_capture_source.index = i;
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_capture_source, chip));
if (err < 0)
return err;
}
if (ac97_can_spdif(chip->ac97)) {
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_dxs3_spdif_control, chip));
if (err < 0)
return err;
}
if (chip->chip_type != TYPE_VIA8233A) {
snd_via8233_dxs_volume_control.count = 1;
snd_via8233_dxs_volume_control.name = "PCM 1";
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_dxs_volume_control, chip));
snd_via8233_dxs_volume_control.name = "PCM 2";
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_dxs_volume_control, chip));
snd_via8233_dxs_volume_control.name = "PCM 3";
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_dxs_volume_control, chip));
snd_via8233_dxs_volume_control.name = "PCM 4";
err = snd_ctl_add(chip->card,
snd_ctl_new1(&snd_via8233_dxs_volume_control, chip));
if (err < 0)
return err;
}
as expected they bound togehter then ;)
now i dont write several callbacks for every, is there a trick here?
this is little nebulous...
static int snd_via8233_dxs_volume_put(snd_kcontrol_t *kcontrol,
snd_ctl_elem_value_t *ucontrol)
{
via82xx_t *chip = snd_kcontrol_chip(kcontrol);
unsigned int idx = snd_ctl_get_ioff(kcontrol, &ucontrol->id);
unsigned long port = chip->port + 0x10 * idx;
unsigned char val;
int i, change = 0;
for (i = 0; i < 2; i++) {
val = ucontrol->value.integer.value[i];
if (val > VIA_DXS_MAX_VOLUME)
val = VIA_DXS_MAX_VOLUME;
val = VIA_DXS_MAX_VOLUME - val;
change |= val != chip->playback_volume[idx][i];
if (change) {
chip->playback_volume[idx][i] = val;
outb(val, port + VIA_REG_OFS_PLAYBACK_VOLUME_L + i);
}
tom
>
> Lee
>
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
prev parent reply other threads:[~2005-02-20 21:03 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-17 22:11 CMI8768 patch "Tien, C.L. - 田承禮"
2005-02-18 10:27 ` Takashi Iwai
2005-02-18 10:58 ` Takashi Iwai
2005-02-19 5:07 ` CMI8768 patch, CMI9761A thomas schorpp
2005-02-19 7:43 ` CMI8768 patch, softvol mixer slider thomas schorpp
2005-02-19 7:56 ` Lee Revell
2005-02-19 18:40 ` thomas schorpp
2005-02-19 19:11 ` Lee Revell
2005-02-19 21:08 ` softvol plugin thomas schorpp
2005-02-19 21:12 ` Lee Revell
2005-02-20 21:03 ` thomas schorpp [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4218FB13.2020507@gmx.de \
--to=t.schorpp@gmx.de \
--cc=alsa-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox