| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "chromecast/media/cma/backend/alsa/stream_mixer_alsa.h" | 5 #include "chromecast/media/cma/backend/alsa/stream_mixer_alsa.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 #include <limits> | 9 #include <limits> |
| 10 #include <utility> | 10 #include <utility> |
| 11 | 11 |
| 12 #include "base/bind_helpers.h" | 12 #include "base/bind_helpers.h" |
| 13 #include "base/command_line.h" | 13 #include "base/command_line.h" |
| 14 #include "base/lazy_instance.h" | 14 #include "base/lazy_instance.h" |
| 15 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
| 16 #include "base/single_thread_task_runner.h" | 16 #include "base/single_thread_task_runner.h" |
| 17 #include "base/strings/string_number_conversions.h" | 17 #include "base/strings/string_number_conversions.h" |
| 18 #include "base/thread_task_runner_handle.h" | 18 #include "base/threading/thread_task_runner_handle.h" |
| 19 #include "chromecast/base/chromecast_switches.h" | 19 #include "chromecast/base/chromecast_switches.h" |
| 20 #include "chromecast/media/cma/backend/alsa/alsa_wrapper.h" | 20 #include "chromecast/media/cma/backend/alsa/alsa_wrapper.h" |
| 21 #include "chromecast/media/cma/backend/alsa/stream_mixer_alsa_input_impl.h" | 21 #include "chromecast/media/cma/backend/alsa/stream_mixer_alsa_input_impl.h" |
| 22 #include "media/base/audio_bus.h" | 22 #include "media/base/audio_bus.h" |
| 23 #include "media/base/media_switches.h" | 23 #include "media/base/media_switches.h" |
| 24 #include "media/base/vector_math.h" | 24 #include "media/base/vector_math.h" |
| 25 | 25 |
| 26 #define RETURN_REPORT_ERROR(snd_func, ...) \ | 26 #define RETURN_REPORT_ERROR(snd_func, ...) \ |
| 27 do { \ | 27 do { \ |
| 28 int err = alsa_->snd_func(__VA_ARGS__); \ | 28 int err = alsa_->snd_func(__VA_ARGS__); \ |
| (...skipping 809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 838 DCHECK(std::find(loopback_observers_.begin(), loopback_observers_.end(), | 838 DCHECK(std::find(loopback_observers_.begin(), loopback_observers_.end(), |
| 839 observer) != loopback_observers_.end()); | 839 observer) != loopback_observers_.end()); |
| 840 loopback_observers_.erase(std::remove(loopback_observers_.begin(), | 840 loopback_observers_.erase(std::remove(loopback_observers_.begin(), |
| 841 loopback_observers_.end(), observer), | 841 loopback_observers_.end(), observer), |
| 842 loopback_observers_.end()); | 842 loopback_observers_.end()); |
| 843 observer->OnRemoved(); | 843 observer->OnRemoved(); |
| 844 } | 844 } |
| 845 | 845 |
| 846 } // namespace media | 846 } // namespace media |
| 847 } // namespace chromecast | 847 } // namespace chromecast |
| OLD | NEW |