Permalink
Browse files

Merge pull request #3 from Kra1o5/ics

Fix audio volume in call
  • Loading branch information...
2 parents 967d4c8 + ebc42da commit 9fb1ae57bafbf242e809c643e3da4038acdb6e2d @Dazzozo committed Jun 10, 2013
Showing with 5 additions and 8 deletions.
  1. +5 −6 audio/AudioHardware.cpp
  2. +0 −1 configs/AutoVolumeControl.txt
  3. +0 −1 device.mk
View
@@ -1151,15 +1151,14 @@ status_t AudioHardware::setVoiceVolume(float v)
LOGW("setVoiceVolume(%f) over 1.0, assuming 1.0\n", v);
v = 1.0;
}
- // Added 0.4 to current volume, as in voice call Mute cannot be set as minimum volume(0.00)
- // setting Rx volume level as 2 for minimum and 7 as max level.
- if (v < 0.4) {
- v = 0.4;
+ // Added 0.2 to current volume, as in voice call Mute cannot be set as minimum volume(0.00)
+ // setting Rx volume level as 1 for minimum and 6 as max level.
+ v = 0.2 + v;
}
- int vol = lrint(v * 5.0);
+ int vol = lrint(v * 3.0);
LOGD("setVoiceVolume(%f)\n", v);
- LOGI("Setting in-call volume to %d (available range is 2 to 7)\n", vol);
+ LOGI("Setting in-call volume to %d (available range is 1 to 6)\n", vol);
if ((mCurSndDevice != -1) && ((mCurSndDevice == SND_DEVICE_TTY_HEADSET) || (mCurSndDevice == SND_DEVICE_TTY_VCO)))
{
@@ -1 +0,0 @@
-1
View
@@ -77,7 +77,6 @@ PRODUCT_COPY_FILES += \
PRODUCT_COPY_FILES += \
device/huawei/u8815/configs/audio_policy.conf:system/etc/audio_policy.conf \
device/huawei/u8815/configs/AudioFilter.csv:system/etc/AudioFilter.csv \
- device/huawei/u8815/configs/AutoVolumeControl.txt:system/etc/AutoVolumeControl.txt \
device/huawei/u8815/configs/media_profiles.xml:system/etc/media_profiles.xml \
device/huawei/u8815/configs/nfcee_access.xml:system/etc/nfcee_access.xml \
device/huawei/u8815/configs/libcm.sh:system/etc/libcm.sh \

0 comments on commit 9fb1ae5

Please sign in to comment.