All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH - ALSA - emu10k1] Add dB range to Bass and Treble controls for SB Live!
@ 2011-05-20  7:04 Raymond Yau
  2011-05-20  7:08 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: Raymond Yau @ 2011-05-20  7:04 UTC (permalink / raw)
  To: ALSA Development Mailing List, Takashi Iwai

[-- Attachment #1: Type: text/plain, Size: 224 bytes --]

As the "Wave", "Wave Surround" or "Front" Playback Volume must be
changed to 70% (i.e. -12 dB) so that distortion won't occur when
increase Bass and Treble from 50% to 100%, so the maximum gain in Bass
and Treble are +12 dB

[-- Attachment #2: 0001-Add-dB-range-to-Bass-and-Treble-for-SB-Live.patch --]
[-- Type: application/octet-stream, Size: 1709 bytes --]

From 04e939a9faddf7d6700ddf581dc2068b0c7c5e9b Mon Sep 17 00:00:00 2001
From: Raymond Yau <superquad.vortex2@gmail.com>
Date: Fri, 20 May 2011 14:32:04 +0800
Subject: [PATCH - ALSA - emu10k1] Add dB range to Bass and Treble for SB Live!

As the "Wave", "Wave Surround" or "Front" Playback Volume must be changed to 70% (i.e. -12 dB) so that distortion won't occur when increase Bass and Treble from 50% to 100%, so the maximum gain in Bass and Treble are +12 dB

Signed-off-by: Raymond Yau <superquad.vortex2@gmail.com>

diff --git a/sound/pci/emu10k1/emufx.c b/sound/pci/emu10k1/emufx.c
index 7a94014..dae4050 100644
--- a/sound/pci/emu10k1/emufx.c
+++ b/sound/pci/emu10k1/emufx.c
@@ -303,6 +303,9 @@ static const u32 db_table[101] = {
 static const DECLARE_TLV_DB_SCALE(snd_emu10k1_db_scale1, -4000, 40, 1);
 static const DECLARE_TLV_DB_LINEAR(snd_emu10k1_db_linear, TLV_DB_GAIN_MUTE, 0);
 
+/* EMU10K1 bass/treble db gain */
+static const DECLARE_TLV_DB_SCALE(snd_emu10k1_bass_treble_db_scale, -1200, 60, 0);
+
 static const u32 onoff_table[2] = {
 	0x00000000, 0x00000001
 };
@@ -2163,6 +2166,7 @@ static int __devinit _snd_emu10k1_init_efx(struct snd_emu10k1 *emu)
 	ctl->min = 0;
 	ctl->max = 40;
 	ctl->value[0] = ctl->value[1] = 20;
+	ctl->tlv = snd_emu10k1_bass_treble_db_scale;
 	ctl->translation = EMU10K1_GPR_TRANSLATION_BASS;
 	ctl = &controls[i + 1];
 	ctl->id.iface = SNDRV_CTL_ELEM_IFACE_MIXER;
@@ -2172,6 +2176,7 @@ static int __devinit _snd_emu10k1_init_efx(struct snd_emu10k1 *emu)
 	ctl->min = 0;
 	ctl->max = 40;
 	ctl->value[0] = ctl->value[1] = 20;
+	ctl->tlv = snd_emu10k1_bass_treble_db_scale;
 	ctl->translation = EMU10K1_GPR_TRANSLATION_TREBLE;
 
 #define BASS_GPR	0x8c
-- 
1.6.0.6


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH - ALSA - emu10k1] Add dB range to Bass and Treble controls for SB Live!
  2011-05-20  7:04 [PATCH - ALSA - emu10k1] Add dB range to Bass and Treble controls for SB Live! Raymond Yau
@ 2011-05-20  7:08 ` Takashi Iwai
  0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2011-05-20  7:08 UTC (permalink / raw)
  To: Raymond Yau; +Cc: ALSA Development Mailing List

At Fri, 20 May 2011 15:04:07 +0800,
Raymond Yau wrote:
> 
> As the "Wave", "Wave Surround" or "Front" Playback Volume must be
> changed to 70% (i.e. -12 dB) so that distortion won't occur when
> increase Bass and Treble from 50% to 100%, so the maximum gain in Bass
> and Treble are +12 dB

Applied now.  Thanks!


Takashi

> [2 0001-Add-dB-range-to-Bass-and-Treble-for-SB-Live.patch <application/octet-stream (base64)>]
> 
> [3  <text/plain; us-ascii (7bit)>]
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-05-20  7:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-20  7:04 [PATCH - ALSA - emu10k1] Add dB range to Bass and Treble controls for SB Live! Raymond Yau
2011-05-20  7:08 ` Takashi Iwai

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.