Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ |
| 6 #define CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ | 6 #define CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 378 // Cached value of the current audio delay on the input/capture side. | 378 // Cached value of the current audio delay on the input/capture side. |
| 379 int input_delay_ms_; | 379 int input_delay_ms_; |
| 380 | 380 |
| 381 // Cached value of the current audio delay on the output/renderer side. | 381 // Cached value of the current audio delay on the output/renderer side. |
| 382 int output_delay_ms_; | 382 int output_delay_ms_; |
| 383 | 383 |
| 384 // Protects |recording_|, |output_delay_ms_|, |input_delay_ms_|, |renderer_| | 384 // Protects |recording_|, |output_delay_ms_|, |input_delay_ms_|, |renderer_| |
| 385 // |recording_| and |microphone_volume_|. | 385 // |recording_| and |microphone_volume_|. |
| 386 mutable base::Lock lock_; | 386 mutable base::Lock lock_; |
| 387 | 387 |
| 388 // Used to protect the racing of calling OnData() since there can be more | |
| 389 // than one input streams calling OnData(). | |
|
henrika (OOO until Aug 14)
2014/01/09 10:07:14
Do we know on which threads these calls are made?
no longer working on chromium
2014/01/09 10:18:32
Threads can be the from WebRtcAudioCapturer and fr
| |
| 390 mutable base::Lock capture_callback_lock_; | |
| 391 | |
| 388 bool initialized_; | 392 bool initialized_; |
| 389 bool playing_; | 393 bool playing_; |
| 390 bool recording_; | 394 bool recording_; |
| 391 | 395 |
| 392 // Used for histograms of total recording and playout times. | 396 // Used for histograms of total recording and playout times. |
| 393 base::Time start_capture_time_; | 397 base::Time start_capture_time_; |
| 394 base::Time start_render_time_; | 398 base::Time start_render_time_; |
| 395 | 399 |
| 396 // Stores latest microphone volume received in a CaptureData() callback. | 400 // Stores latest microphone volume received in a CaptureData() callback. |
| 397 // Range is [0, 255]. | 401 // Range is [0, 255]. |
| 398 uint32_t microphone_volume_; | 402 uint32_t microphone_volume_; |
| 399 | 403 |
| 400 DISALLOW_COPY_AND_ASSIGN(WebRtcAudioDeviceImpl); | 404 DISALLOW_COPY_AND_ASSIGN(WebRtcAudioDeviceImpl); |
| 401 }; | 405 }; |
| 402 | 406 |
| 403 } // namespace content | 407 } // namespace content |
| 404 | 408 |
| 405 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ | 409 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_AUDIO_DEVICE_IMPL_H_ |
| OLD | NEW |