| 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/audio/audio_manager_base.h" | 5 #include "media/audio/audio_manager_base.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/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 | 32 |
| 33 const char AudioManagerBase::kDefaultDeviceName[] = "Default"; | 33 const char AudioManagerBase::kDefaultDeviceName[] = "Default"; |
| 34 const char AudioManagerBase::kDefaultDeviceId[] = "default"; | 34 const char AudioManagerBase::kDefaultDeviceId[] = "default"; |
| 35 const char AudioManagerBase::kLoopbackInputDeviceId[] = "loopback"; | 35 const char AudioManagerBase::kLoopbackInputDeviceId[] = "loopback"; |
| 36 | 36 |
| 37 struct AudioManagerBase::DispatcherParams { | 37 struct AudioManagerBase::DispatcherParams { |
| 38 DispatcherParams(const AudioParameters& input, | 38 DispatcherParams(const AudioParameters& input, |
| 39 const AudioParameters& output, | 39 const AudioParameters& output, |
| 40 const std::string& output_device_id) | 40 const std::string& output_device_id) |
| 41 : input_params(input), | 41 : input_params(input), |
| 42 output_params(output) {} | 42 output_params(output), |
| 43 output_device_id(output_device_id) {} |
| 43 ~DispatcherParams() {} | 44 ~DispatcherParams() {} |
| 44 | 45 |
| 45 const AudioParameters input_params; | 46 const AudioParameters input_params; |
| 46 const AudioParameters output_params; | 47 const AudioParameters output_params; |
| 47 const std::string output_device_id; | 48 const std::string output_device_id; |
| 48 scoped_refptr<AudioOutputDispatcher> dispatcher; | 49 scoped_refptr<AudioOutputDispatcher> dispatcher; |
| 49 | 50 |
| 50 private: | 51 private: |
| 51 DISALLOW_COPY_AND_ASSIGN(DispatcherParams); | 52 DISALLOW_COPY_AND_ASSIGN(DispatcherParams); |
| 52 }; | 53 }; |
| (...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 436 (*it)->dispatcher->CloseStreamsForWedgeFix(); | 437 (*it)->dispatcher->CloseStreamsForWedgeFix(); |
| 437 } | 438 } |
| 438 for (AudioOutputDispatchers::iterator it = output_dispatchers_.begin(); | 439 for (AudioOutputDispatchers::iterator it = output_dispatchers_.begin(); |
| 439 it != output_dispatchers_.end(); ++it) { | 440 it != output_dispatchers_.end(); ++it) { |
| 440 (*it)->dispatcher->RestartStreamsForWedgeFix(); | 441 (*it)->dispatcher->RestartStreamsForWedgeFix(); |
| 441 } | 442 } |
| 442 #endif | 443 #endif |
| 443 } | 444 } |
| 444 | 445 |
| 445 } // namespace media | 446 } // namespace media |
| OLD | NEW |