| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "media/base/multi_channel_resampler.h" | 5 #include "media/base/multi_channel_resampler.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "media/base/audio_bus.h" | 10 #include "media/base/audio_bus.h" |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 DCHECK(!resamplers_.empty()); | 112 DCHECK(!resamplers_.empty()); |
| 113 return resamplers_[0]->ChunkSize(); | 113 return resamplers_[0]->ChunkSize(); |
| 114 } | 114 } |
| 115 | 115 |
| 116 | 116 |
| 117 double MultiChannelResampler::BufferedFrames() const { | 117 double MultiChannelResampler::BufferedFrames() const { |
| 118 DCHECK(!resamplers_.empty()); | 118 DCHECK(!resamplers_.empty()); |
| 119 return resamplers_[0]->BufferedFrames(); | 119 return resamplers_[0]->BufferedFrames(); |
| 120 } | 120 } |
| 121 | 121 |
| 122 void MultiChannelResampler::PrimeWithSilence() { |
| 123 DCHECK(!resamplers_.empty()); |
| 124 for (size_t i = 0; i < resamplers_.size(); ++i) |
| 125 resamplers_[i]->PrimeWithSilence(); |
| 126 } |
| 122 | 127 |
| 123 } // namespace media | 128 } // namespace media |
| OLD | NEW |