summaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authorUK KIM <w0806.kim@samsung.com>2011-10-26 20:56:21 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2011-10-26 20:56:21 +0000
commitbc3182aead6e278504ebd04484cde4c3c9130901 (patch)
tree1b8aabf7dee781ec7e65a3885a7591c3ab8df5cf /audio
parenta3c45533f318d32c42113429947d8bd9a319f414 (diff)
parent56e8b292cb2aa15804eb436d48c71e1a98b36550 (diff)
downloaddevice_samsung_tuna-bc3182aead6e278504ebd04484cde4c3c9130901.zip
device_samsung_tuna-bc3182aead6e278504ebd04484cde4c3c9130901.tar.gz
device_samsung_tuna-bc3182aead6e278504ebd04484cde4c3c9130901.tar.bz2
am 56e8b292: am e6f399a5: audio: decrease headset gain by 14dB for ringtone mode
* commit '56e8b292cb2aa15804eb436d48c71e1a98b36550': audio: decrease headset gain by 14dB for ringtone mode
Diffstat (limited to 'audio')
-rwxr-xr-xaudio/audio_hw.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/audio/audio_hw.c b/audio/audio_hw.c
index 97cdf4d..079acd7 100755
--- a/audio/audio_hw.c
+++ b/audio/audio_hw.c
@@ -206,6 +206,7 @@
#define VOIP_EARPIECE_VOLUME_MAGURO 6
#define HEADPHONE_VOLUME_TTY -2
+#define RINGTONE_HEADSET_VOLUME_OFFSET -14
/* product-specific defines */
#define PRODUCT_DEVICE_PROPERTY "ro.product.device"
@@ -817,6 +818,8 @@ static void set_output_volumes(struct tuna_audio_device *adev, bool tty_volume)
}
if (tty_volume)
headset_volume = HEADPHONE_VOLUME_TTY;
+ else if (adev->mode == AUDIO_MODE_RINGTONE)
+ headset_volume += RINGTONE_HEADSET_VOLUME_OFFSET;
/* If we have run out of range in the codec (analog) speaker volume,
we have to apply the remainder of the dB increase to the DL2