summaryrefslogtreecommitdiff
path: root/voice_engine/voe_base_impl.h
diff options
context:
space:
mode:
authorandrew@webrtc.org <andrew@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-02-18 20:24:56 +0000
committerandrew@webrtc.org <andrew@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-02-18 20:24:56 +0000
commitad065d00af1d67641f9dbba6b6842d68daa714c1 (patch)
tree0c07e2fbcd46dc9a2a2363b99019cc5f97d7c7d0 /voice_engine/voe_base_impl.h
parentf6c4fc37636a466cc1f8f11bfee9ad42c0d05473 (diff)
downloadwebrtc-ad065d00af1d67641f9dbba6b6842d68daa714c1.tar.gz
Move the volume quantization workaround from VoE to AGC.
Voice engine shouldn't really have to manage this. Instead, have AGC keep track of the last input volume, so that it can avoid getting stuck under coarsely quantized conditions. Add a test to verify the behavior. TESTED=unittests, and observed that AGC didn't get stuck on a MacBook where this problem can actually occur. R=bjornv@webrtc.org Review URL: https://webrtc-codereview.appspot.com/8729004 git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@5571 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'voice_engine/voe_base_impl.h')
-rw-r--r--voice_engine/voe_base_impl.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/voice_engine/voe_base_impl.h b/voice_engine/voe_base_impl.h
index 00e116ea..df406eb9 100644
--- a/voice_engine/voe_base_impl.h
+++ b/voice_engine/voe_base_impl.h
@@ -80,7 +80,7 @@ public:
uint32_t samplesPerSec,
uint32_t totalDelayMS,
int32_t clockDrift,
- uint32_t currentMicLevel,
+ uint32_t micLevel,
bool keyPressed,
uint32_t& newMicLevel);
@@ -98,7 +98,7 @@ public:
int number_of_channels,
int number_of_frames,
int audio_delay_milliseconds,
- int current_volume,
+ int volume,
bool key_pressed,
bool need_audio_processing);
@@ -135,7 +135,7 @@ private:
uint32_t number_of_frames,
uint32_t audio_delay_milliseconds,
int32_t clock_drift,
- uint32_t current_volume,
+ uint32_t volume,
bool key_pressed);
int32_t AddBuildInfo(char* str) const;
@@ -154,8 +154,6 @@ private:
CriticalSectionWrapper& _callbackCritSect;
bool _voiceEngineObserver;
- uint32_t _oldVoEMicLevel;
- uint32_t _oldMicLevel;
AudioFrame _audioFrame;
voe::SharedData* _shared;
};