OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/test_runner/mock_web_audio_device.h" | 5 #include "components/test_runner/mock_web_audio_device.h" |
6 | 6 |
7 namespace test_runner { | 7 namespace test_runner { |
8 | 8 |
9 MockWebAudioDevice::MockWebAudioDevice(double sample_rate) | 9 MockWebAudioDevice::MockWebAudioDevice(double sample_rate, |
10 : sample_rate_(sample_rate) {} | 10 int frames_per_buffer) |
| 11 : sample_rate_(sample_rate), frames_per_buffer_(frames_per_buffer) {} |
11 | 12 |
12 MockWebAudioDevice::~MockWebAudioDevice() {} | 13 MockWebAudioDevice::~MockWebAudioDevice() {} |
13 | 14 |
14 void MockWebAudioDevice::start() {} | 15 void MockWebAudioDevice::start() {} |
15 | 16 |
16 void MockWebAudioDevice::stop() {} | 17 void MockWebAudioDevice::stop() {} |
17 | 18 |
18 double MockWebAudioDevice::sampleRate() { | 19 double MockWebAudioDevice::sampleRate() { |
19 return sample_rate_; | 20 return sample_rate_; |
20 } | 21 } |
21 | 22 |
| 23 int MockWebAudioDevice::framesPerBuffer() { |
| 24 return frames_per_buffer_; |
| 25 } |
| 26 |
22 } // namespace test_runner | 27 } // namespace test_runner |
OLD | NEW |