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

Unified Diff: media/audio/audio_input_device.cc

Issue 2689483006: Switch browser side audio capture path to use base time primitives. (Closed)
Patch Set: Bloop Created 3 years, 10 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/audio_input_device.cc
diff --git a/media/audio/audio_input_device.cc b/media/audio/audio_input_device.cc
index aa44d9d7552e0c4f40cf550465aa891fdf8edec9..bc22d38fd4e9bdee8afd377ab4013f27db4ed778 100644
--- a/media/audio/audio_input_device.cc
+++ b/media/audio/audio_input_device.cc
@@ -335,9 +335,10 @@ void AudioInputDevice::AudioThreadCallback::Process(uint32_t pending_data) {
// Deliver captured data to the client in floating point format and update
// the audio delay measurement.
+ // TODO(olka, tommi): Do something with |delay_timestamp|.
capture_callback_->Capture(
audio_bus,
- buffer->params.hardware_delay_bytes / bytes_per_ms_, // Delay in ms
+ base::TimeDelta::FromMicroseconds(buffer->params.delay).InMilliseconds(),
buffer->params.volume, buffer->params.key_pressed);
if (++current_segment_id_ >= total_segments_)

Powered by Google App Engine
This is Rietveld 408576698