Chromium Code Reviews| Index: media/audio/audio_input_controller.h |
| diff --git a/media/audio/audio_input_controller.h b/media/audio/audio_input_controller.h |
| index b21eabadaf2fce91bdfbb5f02a32b54b9a3c4a4a..df3e897132843229ce1e199352db1285bd8a6df5 100644 |
| --- a/media/audio/audio_input_controller.h |
| +++ b/media/audio/audio_input_controller.h |
| @@ -100,6 +100,7 @@ class AudioInputController |
| // AudioInputController being created directly. |
| #if defined(UNIT_TEST) |
| static void set_factory(Factory* factory) { factory_ = factory; } |
| + AudioInputStream* getAudioInputStream() { return stream_; } |
|
scherkus (not reviewing)
2011/06/13 19:04:56
nit: should be stream()
allanwoj
2011/06/14 15:03:12
Done.
|
| #endif |
| // Starts recording in this audio input stream. |
| @@ -138,10 +139,18 @@ class AudioInputController |
| void DoRecord(); |
| void DoClose(); |
| void DoReportError(int code); |
| + void DoDataCountCheck(); |
| + |
| + void ScheduleDataCountCheck(); |
| EventHandler* handler_; |
| AudioInputStream* stream_; |
| + // Incremented on each call to OnData. |
| + int on_data_call_count_; |
| + // Only used on the audio controller thread. |
| + int previous_on_data_count_; |
| + |
| // |state_| is written on the audio input controller thread and is read on |
| // the hardware audio thread. These operations need to be locked. But lock |
| // is not required for reading on the audio input controller thread. |