Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2480)

Unified Diff: media/audio/win/audio_low_latency_input_win.cc

Issue 15563004: Improved AGC update scheme for the audio backend in Chrome (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More changes based on feedback from tommi@ Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/audio/win/audio_low_latency_input_win.cc
diff --git a/media/audio/win/audio_low_latency_input_win.cc b/media/audio/win/audio_low_latency_input_win.cc
index ae4c630f78245248afb09ac4fe748b69c184d7f2..5c7b5e9aa6fa15c8d60712dbf7f4b022f6e5f8c1 100644
--- a/media/audio/win/audio_low_latency_input_win.cc
+++ b/media/audio/win/audio_low_latency_input_win.cc
@@ -387,10 +387,10 @@ void WASAPIAudioInputStream::Run() {
first_audio_frame_timestamp) / 10000.0) * ms_to_frame_count_ +
buffer_frame_index - num_frames_to_read;
- // Update the AGC volume level once every second. Note that,
- // |volume| is also updated each time SetVolume() is called
- // through IPC by the render-side AGC.
- QueryAgcVolume(&volume);
+ // Get a cached AGC volume level which is updated once every second
+ // on the audio manager thread. Note that, |volume| is also updated
+ // each time SetVolume() is called through IPC by the render-side AGC.
+ GetAgcVolume(&volume);
// Deliver captured data to the registered consumer using a packet
// size which was specified at construction.

Powered by Google App Engine
This is Rietveld 408576698