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

Side by Side Diff: media/audio/android/audio_manager_android.h

Issue 115413002: Enable platform echo cancellation through the AudioRecord path. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 7 years 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
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 #ifndef MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_ 5 #ifndef MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_
6 #define MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_ 6 #define MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_
7 7
8 #include <set> 8 #include <set>
9 9
10 #include "base/android/jni_android.h" 10 #include "base/android/jni_android.h"
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 void SetAudioMode(int mode); 72 void SetAudioMode(int mode);
73 void SetAudioDevice(const std::string& device_id); 73 void SetAudioDevice(const std::string& device_id);
74 int GetNativeOutputSampleRate(); 74 int GetNativeOutputSampleRate();
75 bool IsAudioLowLatencySupported(); 75 bool IsAudioLowLatencySupported();
76 int GetAudioLowLatencyOutputFrameSize(); 76 int GetAudioLowLatencyOutputFrameSize();
77 int GetOptimalOutputFrameSize(int sample_rate, int channels); 77 int GetOptimalOutputFrameSize(int sample_rate, int channels);
78 78
79 void DoSetMuteOnAudioThread(bool muted); 79 void DoSetMuteOnAudioThread(bool muted);
80 80
81 // Allow the AudioAndroidTest to access private methods. 81 // Allow the AudioAndroidTest to access private methods.
82 FRIEND_TEST_ALL_PREFIXES(AudioAndroidTest, IsAudioLowLatencySupported); 82 FRIEND_TEST_ALL_PREFIXES(AudioAndroidOutputTest, IsAudioLowLatencySupported);
83 83
84 // Java AudioManager instance. 84 // Java AudioManager instance.
85 base::android::ScopedJavaGlobalRef<jobject> j_audio_manager_; 85 base::android::ScopedJavaGlobalRef<jobject> j_audio_manager_;
86 86
87 typedef std::set<OpenSLESOutputStream*> OutputStreams; 87 typedef std::set<OpenSLESOutputStream*> OutputStreams;
88 OutputStreams streams_; 88 OutputStreams streams_;
89 // TODO(wjia): remove this lock once unit test modules are fixed to call 89 // TODO(wjia): remove this lock once unit test modules are fixed to call
90 // AudioManager::MakeAudioOutputStream on the audio thread. For now, this 90 // AudioManager::MakeAudioOutputStream on the audio thread. For now, this
91 // lock is used to guard access to |streams_|. 91 // lock is used to guard access to |streams_|.
92 base::Lock streams_lock_; 92 base::Lock streams_lock_;
93 93
94 DISALLOW_COPY_AND_ASSIGN(AudioManagerAndroid); 94 DISALLOW_COPY_AND_ASSIGN(AudioManagerAndroid);
95 }; 95 };
96 96
97 } // namespace media 97 } // namespace media
98 98
99 #endif // MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_ 99 #endif // MEDIA_AUDIO_ANDROID_AUDIO_MANAGER_ANDROID_H_
OLDNEW
« no previous file with comments | « media/audio/android/audio_android_unittest.cc ('k') | media/audio/android/audio_manager_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698