OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 <stdint.h> |
| 6 |
5 #include "base/time/time.h" | 7 #include "base/time/time.h" |
6 #include "media/base/audio_bus.h" | 8 #include "media/base/audio_bus.h" |
7 #include "media/base/fake_audio_render_callback.h" | 9 #include "media/base/fake_audio_render_callback.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
9 #include "testing/perf/perf_test.h" | 11 #include "testing/perf/perf_test.h" |
10 | 12 |
11 namespace media { | 13 namespace media { |
12 | 14 |
13 static const int kBenchmarkIterations = 20; | 15 static const int kBenchmarkIterations = 20; |
14 | 16 |
(...skipping 29 matching lines...) Expand all Loading... |
44 scoped_ptr<AudioBus> bus = AudioBus::Create(2, 48000 * 120); | 46 scoped_ptr<AudioBus> bus = AudioBus::Create(2, 48000 * 120); |
45 FakeAudioRenderCallback callback(0.2); | 47 FakeAudioRenderCallback callback(0.2); |
46 callback.Render(bus.get(), 0, 0); | 48 callback.Render(bus.get(), 0, 0); |
47 | 49 |
48 RunInterleaveBench<int8_t>(bus.get(), "int8_t"); | 50 RunInterleaveBench<int8_t>(bus.get(), "int8_t"); |
49 RunInterleaveBench<int16_t>(bus.get(), "int16_t"); | 51 RunInterleaveBench<int16_t>(bus.get(), "int16_t"); |
50 RunInterleaveBench<int32_t>(bus.get(), "int32_t"); | 52 RunInterleaveBench<int32_t>(bus.get(), "int32_t"); |
51 } | 53 } |
52 | 54 |
53 } // namespace media | 55 } // namespace media |
OLD | NEW |