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

Side by Side Diff: webrtc/modules/audio_device/audio_device_impl.cc

Issue 1206783002: Cleanup of iOS AudioDevice implementation (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebased Created 5 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 #endif 318 #endif
319 } 319 }
320 #endif // #if defined(WEBRTC_LINUX) 320 #endif // #if defined(WEBRTC_LINUX)
321 321
322 // Create the *iPhone* implementation of the Audio Device 322 // Create the *iPhone* implementation of the Audio Device
323 // 323 //
324 #if defined(WEBRTC_IOS) 324 #if defined(WEBRTC_IOS)
325 if (audioLayer == kPlatformDefaultAudio) 325 if (audioLayer == kPlatformDefaultAudio)
326 { 326 {
327 // Create iOS Audio Device implementation. 327 // Create iOS Audio Device implementation.
328 ptrAudioDevice = new AudioDeviceIOS(Id()); 328 ptrAudioDevice = new AudioDeviceIOS();
329 WEBRTC_TRACE(kTraceInfo, kTraceAudioDevice, _id, "iPhone Audio APIs will be utilized"); 329 WEBRTC_TRACE(kTraceInfo, kTraceAudioDevice, _id, "iPhone Audio APIs will be utilized");
330 } 330 }
331 // END #if defined(WEBRTC_IOS) 331 // END #if defined(WEBRTC_IOS)
332 332
333 // Create the *Mac* implementation of the Audio Device 333 // Create the *Mac* implementation of the Audio Device
334 // 334 //
335 #elif defined(WEBRTC_MAC) 335 #elif defined(WEBRTC_MAC)
336 if (audioLayer == kPlatformDefaultAudio) 336 if (audioLayer == kPlatformDefaultAudio)
337 { 337 {
338 // Create *Mac Audio* implementation 338 // Create *Mac Audio* implementation
(...skipping 1553 matching lines...) Expand 10 before | Expand all | Expand 10 after
1892 CHECK_INITIALIZED_BOOL(); 1892 CHECK_INITIALIZED_BOOL();
1893 1893
1894 return _ptrAudioDevice->BuiltInAECIsEnabled(); 1894 return _ptrAudioDevice->BuiltInAECIsEnabled();
1895 } 1895 }
1896 1896
1897 bool AudioDeviceModuleImpl::BuiltInAECIsAvailable() const { 1897 bool AudioDeviceModuleImpl::BuiltInAECIsAvailable() const {
1898 CHECK_INITIALIZED_BOOL(); 1898 CHECK_INITIALIZED_BOOL();
1899 return _ptrAudioDevice->BuiltInAECIsAvailable(); 1899 return _ptrAudioDevice->BuiltInAECIsAvailable();
1900 } 1900 }
1901 1901
1902 int AudioDeviceModuleImpl::GetPlayoutAudioParameters(
1903 AudioParameters* params) const {
1904 return _ptrAudioDevice->GetPlayoutAudioParameters(params);
1905 }
1906
1907 int AudioDeviceModuleImpl::GetRecordAudioParameters(
1908 AudioParameters* params) const {
1909 return _ptrAudioDevice->GetRecordAudioParameters(params);
1910 }
1911
1902 // ============================================================================ 1912 // ============================================================================
1903 // Private Methods 1913 // Private Methods
1904 // ============================================================================ 1914 // ============================================================================
1905 1915
1906 // ---------------------------------------------------------------------------- 1916 // ----------------------------------------------------------------------------
1907 // Platform 1917 // Platform
1908 // ---------------------------------------------------------------------------- 1918 // ----------------------------------------------------------------------------
1909 1919
1910 AudioDeviceModuleImpl::PlatformType AudioDeviceModuleImpl::Platform() const 1920 AudioDeviceModuleImpl::PlatformType AudioDeviceModuleImpl::Platform() const
1911 { 1921 {
1912 return _platformType; 1922 return _platformType;
1913 } 1923 }
1914 1924
1915 // ---------------------------------------------------------------------------- 1925 // ----------------------------------------------------------------------------
1916 // PlatformAudioLayer 1926 // PlatformAudioLayer
1917 // ---------------------------------------------------------------------------- 1927 // ----------------------------------------------------------------------------
1918 1928
1919 AudioDeviceModule::AudioLayer AudioDeviceModuleImpl::PlatformAudioLayer() const 1929 AudioDeviceModule::AudioLayer AudioDeviceModuleImpl::PlatformAudioLayer() const
1920 { 1930 {
1921 return _platformAudioLayer; 1931 return _platformAudioLayer;
1922 } 1932 }
1923 1933
1924 } // namespace webrtc 1934 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_device/audio_device_impl.h ('k') | webrtc/modules/audio_device/include/audio_device.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698