Index: trunk/src/media/audio/audio_low_latency_input_output_unittest.cc |
=================================================================== |
--- trunk/src/media/audio/audio_low_latency_input_output_unittest.cc (revision 277811) |
+++ trunk/src/media/audio/audio_low_latency_input_output_unittest.cc (working copy) |
@@ -184,7 +184,7 @@ |
// AudioInputStream::AudioInputCallback. |
virtual void OnData(AudioInputStream* stream, |
- const AudioBus* src, |
+ const uint8* src, uint32 size, |
uint32 hardware_delay_bytes, |
double volume) OVERRIDE { |
base::AutoLock lock(lock_); |
@@ -203,15 +203,14 @@ |
++input_elements_to_write_; |
} |
- // TODO(henrika): fix this and use AudioFifo instead. |
// Store the captured audio packet in a seekable media buffer. |
- // if (!buffer_->Append(src, size)) { |
- // An attempt to write outside the buffer limits has been made. |
- // Double the buffer capacity to ensure that we have a buffer large |
- // enough to handle the current sample test scenario. |
- // buffer_->set_forward_capacity(2 * buffer_->forward_capacity()); |
- // buffer_->Clear(); |
- // } |
+ if (!buffer_->Append(src, size)) { |
+ // An attempt to write outside the buffer limits has been made. |
+ // Double the buffer capacity to ensure that we have a buffer large |
+ // enough to handle the current sample test scenario. |
+ buffer_->set_forward_capacity(2 * buffer_->forward_capacity()); |
+ buffer_->Clear(); |
+ } |
} |
virtual void OnError(AudioInputStream* stream) OVERRIDE {} |