Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(420)

Side by Side Diff: media/audio/linux/audio_manager_linux.cc

Issue 9805001: Move media/audio files into media namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix various compiler errors Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/linux/audio_manager_linux.h" 5 #include "media/audio/linux/audio_manager_linux.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/environment.h" 8 #include "base/environment.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/nix/xdg_util.h" 10 #include "base/nix/xdg_util.h"
11 #include "base/process_util.h" 11 #include "base/process_util.h"
12 #include "base/stl_util.h" 12 #include "base/stl_util.h"
13 #include "media/audio/audio_output_dispatcher.h" 13 #include "media/audio/audio_output_dispatcher.h"
14 #include "media/audio/linux/alsa_input.h" 14 #include "media/audio/linux/alsa_input.h"
15 #include "media/audio/linux/alsa_output.h" 15 #include "media/audio/linux/alsa_output.h"
16 #include "media/audio/linux/alsa_wrapper.h" 16 #include "media/audio/linux/alsa_wrapper.h"
17 #if defined(USE_PULSEAUDIO) 17 #if defined(USE_PULSEAUDIO)
18 #include "media/audio/pulse/pulse_output.h" 18 #include "media/audio/pulse/pulse_output.h"
19 #endif 19 #endif
20 #include "media/base/limits.h" 20 #include "media/base/limits.h"
21 #include "media/base/media_switches.h" 21 #include "media/base/media_switches.h"
22 22
23 namespace media {
24
23 // Maximum number of output streams that can be open simultaneously. 25 // Maximum number of output streams that can be open simultaneously.
24 static const int kMaxOutputStreams = 50; 26 static const int kMaxOutputStreams = 50;
25 27
26 // Since "default", "pulse" and "dmix" devices are virtual devices mapped to 28 // Since "default", "pulse" and "dmix" devices are virtual devices mapped to
27 // real devices, we remove them from the list to avoiding duplicate counting. 29 // real devices, we remove them from the list to avoiding duplicate counting.
28 // In addition, note that we support no more than 2 channels for recording, 30 // In addition, note that we support no more than 2 channels for recording,
29 // hence surround devices are not stored in the list. 31 // hence surround devices are not stored in the list.
30 static const char* kInvalidAudioInputDevices[] = { 32 static const char* kInvalidAudioInputDevices[] = {
31 "default", 33 "default",
32 "null", 34 "null",
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 device_name = CommandLine::ForCurrentProcess()->GetSwitchValueASCII( 293 device_name = CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
292 switches::kAlsaInputDevice); 294 switches::kAlsaInputDevice);
293 } 295 }
294 296
295 return new AlsaPcmInputStream(this, device_name, params, wrapper_.get()); 297 return new AlsaPcmInputStream(this, device_name, params, wrapper_.get());
296 } 298 }
297 299
298 AudioManager* CreateAudioManager() { 300 AudioManager* CreateAudioManager() {
299 return new AudioManagerLinux(); 301 return new AudioManagerLinux();
300 } 302 }
303
304 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698