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

Unified Diff: content/renderer/media/media_stream_audio_processor.h

Issue 1528473003: Feed the WebRTC APM with empty far-end frames for the number of frames skipped by OS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Code review. Rebase. Created 5 years 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
« no previous file with comments | « no previous file | content/renderer/media/media_stream_audio_processor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/media_stream_audio_processor.h
diff --git a/content/renderer/media/media_stream_audio_processor.h b/content/renderer/media/media_stream_audio_processor.h
index f5d5781f3a68d2e79b35d35da98be764b5947c88..295e51354627d8c4981babf2100e8623f4b2a1a1 100644
--- a/content/renderer/media/media_stream_audio_processor.h
+++ b/content/renderer/media/media_stream_audio_processor.h
@@ -121,7 +121,8 @@ class CONTENT_EXPORT MediaStreamAudioProcessor :
// WebRtcPlayoutDataSource::Sink implementation.
void OnPlayoutData(media::AudioBus* audio_bus,
int sample_rate,
- int audio_delay_milliseconds) override;
+ int audio_delay_milliseconds,
+ uint32_t skipped_frames) override;
void OnPlayoutDataSourceChanged() override;
// webrtc::AudioProcessorInterface implementation.
@@ -207,6 +208,10 @@ class CONTENT_EXPORT MediaStreamAudioProcessor :
// the libjingle thread through GetStats().
scoped_ptr<EchoInformation> echo_information_;
+ // Stores the number of skipped output frames. The APM only accepts 10 ms
+ // chunks of data, so we ned to store it until it reaches that amount.
+ uint32_t skipped_output_frames_;
+
DISALLOW_COPY_AND_ASSIGN(MediaStreamAudioProcessor);
};
« no previous file with comments | « no previous file | content/renderer/media/media_stream_audio_processor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698