Chromium Code Reviews| Index: media/audio/audio_output_resampler.cc |
| diff --git a/media/audio/audio_output_resampler.cc b/media/audio/audio_output_resampler.cc |
| index 34343d75337c6598126a3696f252690a9bdfdefb..c945aae4ad4adf1530d8978d8452eda6a59b352f 100644 |
| --- a/media/audio/audio_output_resampler.cc |
| +++ b/media/audio/audio_output_resampler.cc |
| @@ -132,6 +132,16 @@ void AudioOutputResampler::Initialize() { |
| io_ratio_ *= static_cast<double>(params_.channels()) / |
| output_params_.channels(); |
| + // We allow the clients to set the buffer size for low latency path. |
| + if (output_params_.format() == AudioParameters::AUDIO_PCM_LOW_LATENCY && |
| + params_.frames_per_buffer() != output_params_.frames_per_buffer()) { |
|
scherkus (not reviewing)
2012/09/17 16:27:23
doesn't this essentially disable the FIFO when sam
no longer working on chromium
2012/09/17 21:56:28
True, we should not do this.
|
| + output_params_.Reset(output_params_.format(), |
| + output_params_.channel_layout(), |
| + output_params_.sample_rate(), |
| + output_params_.bits_per_sample(), |
| + params_.frames_per_buffer()); |
| + } |
| + |
| // Since the resampler / output device may want a different buffer size than |
| // the caller asked for, we need to use a FIFO to ensure that both sides |
| // read in chunk sizes they're configured for. |