2018-05-15 10:22:36 +02:00
|
|
|
/*
|
|
|
|
|
* Copyright 2018 The WebRTC project authors. All Rights Reserved.
|
|
|
|
|
*
|
|
|
|
|
* Use of this source code is governed by a BSD-style license
|
|
|
|
|
* that can be found in the LICENSE file in the root of the source
|
|
|
|
|
* tree. An additional intellectual property rights grant can be found
|
|
|
|
|
* in the file PATENTS. All contributing project authors may
|
|
|
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#include "audio_device_module.h"
|
|
|
|
|
|
|
|
|
|
#include "rtc_base/logging.h"
|
2019-01-11 09:11:00 -08:00
|
|
|
#include "rtc_base/ref_counted_object.h"
|
2018-05-15 10:22:36 +02:00
|
|
|
|
2018-08-30 09:30:29 +02:00
|
|
|
#include "sdk/objc/native/src/audio/audio_device_module_ios.h"
|
2018-05-15 10:22:36 +02:00
|
|
|
|
|
|
|
|
namespace webrtc {
|
|
|
|
|
|
2020-11-26 12:18:11 +01:00
|
|
|
rtc::scoped_refptr<AudioDeviceModule> CreateAudioDeviceModule(bool bypass_voice_processing) {
|
2021-11-04 12:01:23 +00:00
|
|
|
RTC_DLOG(LS_INFO) << __FUNCTION__;
|
2018-05-15 10:22:36 +02:00
|
|
|
#if defined(WEBRTC_IOS)
|
2022-01-17 15:26:54 +01:00
|
|
|
return rtc::make_ref_counted<ios_adm::AudioDeviceModuleIOS>(bypass_voice_processing);
|
2018-05-15 10:22:36 +02:00
|
|
|
#else
|
2021-11-04 12:01:23 +00:00
|
|
|
RTC_LOG(LS_ERROR) << "current platform is not supported => this module will self destruct!";
|
2018-05-15 10:22:36 +02:00
|
|
|
return nullptr;
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
}
|