Index: webrtc/modules/audio_device/ios/audio_device_not_implemented_ios.mm |
diff --git a/webrtc/modules/audio_device/ios/audio_device_not_implemented_ios.mm b/webrtc/modules/audio_device/ios/audio_device_not_implemented_ios.mm |
new file mode 100644 |
index 0000000000000000000000000000000000000000..45b0fe3c2bbb682553f544885f97c0a48080dda9 |
--- /dev/null |
+++ b/webrtc/modules/audio_device/ios/audio_device_not_implemented_ios.mm |
@@ -0,0 +1,307 @@ |
+/* |
+ * Copyright (c) 2015 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 "webrtc/modules/audio_device/ios/audio_device_not_implemented_ios.h" |
+ |
+#include "webrtc/base/checks.h" |
+#include "webrtc/base/logging.h" |
+ |
+#define TAG "AudioDeviceNotImplementedIOS::" |
+ |
+namespace webrtc { |
+ |
+AudioDeviceNotImplementedIOS::AudioDeviceNotImplementedIOS() { |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::ActiveAudioLayer( |
+ AudioDeviceModule::AudioLayer& audioLayer) const { |
+ audioLayer = AudioDeviceModule::kPlatformDefaultAudio; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::ResetAudioDevice() { |
+ FATAL() << "Not implemented"; |
tkchin_webrtc
2015/07/06 03:46:29
RTC_NOTREACHED?
henrika_webrtc
2015/07/07 16:01:38
Done.
|
+ return -1; |
+} |
+ |
+int16_t AudioDeviceNotImplementedIOS::PlayoutDevices() { |
+ // TODO(henrika): improve. |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return (int16_t)1; |
+} |
+ |
+int16_t AudioDeviceNotImplementedIOS::RecordingDevices() { |
+ // TODO(henrika): improve. |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return (int16_t)1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::InitSpeaker() { |
+ return 0; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::SpeakerIsInitialized() const { |
+ return true; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SpeakerVolumeIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetSpeakerVolume(uint32_t volume) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SpeakerVolume(uint32_t& volume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetWaveOutVolume(uint16_t, uint16_t) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::WaveOutVolume(uint16_t&, |
+ uint16_t&) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MaxSpeakerVolume( |
+ uint32_t& maxVolume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MinSpeakerVolume( |
+ uint32_t& minVolume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SpeakerVolumeStepSize( |
+ uint16_t& stepSize) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SpeakerMuteIsAvailable(bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetSpeakerMute(bool enable) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SpeakerMute(bool& enabled) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetPlayoutDevice(uint16_t index) { |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetPlayoutDevice( |
+ AudioDeviceModule::WindowsDeviceType) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::PlayoutWarning() const { |
+ return false; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::PlayoutError() const { |
+ return false; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::RecordingWarning() const { |
+ return false; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::RecordingError() const { |
+ return false; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::InitMicrophone() { |
+ return 0; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::MicrophoneIsInitialized() const { |
+ return true; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneMuteIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetMicrophoneMute(bool enable) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneMute(bool& enabled) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneBoostIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetMicrophoneBoost(bool enable) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneBoost(bool& enabled) const { |
+ enabled = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::StereoRecordingIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetStereoRecording(bool enable) { |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::StereoRecording(bool& enabled) const { |
+ enabled = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::StereoPlayoutIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetStereoPlayout(bool enable) { |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::StereoPlayout(bool& enabled) const { |
+ enabled = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetAGC(bool enable) { |
+ if (enable) { |
+ FATAL() << "Should never be called"; |
+ } |
+ return -1; |
+} |
+ |
+bool AudioDeviceNotImplementedIOS::AGC() const { |
+ return false; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneVolumeIsAvailable( |
+ bool& available) { |
+ available = false; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetMicrophoneVolume(uint32_t volume) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneVolume(uint32_t& volume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MaxMicrophoneVolume( |
+ uint32_t& maxVolume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MinMicrophoneVolume( |
+ uint32_t& minVolume) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::MicrophoneVolumeStepSize( |
+ uint16_t& stepSize) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::PlayoutDeviceName( |
+ uint16_t index, |
+ char name[kAdmMaxDeviceNameSize], |
+ char guid[kAdmMaxGuidSize]) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::RecordingDeviceName( |
+ uint16_t index, |
+ char name[kAdmMaxDeviceNameSize], |
+ char guid[kAdmMaxGuidSize]) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetRecordingDevice(uint16_t index) { |
+ LOG_F(LS_WARNING) << "Not implemented"; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetRecordingDevice( |
+ AudioDeviceModule::WindowsDeviceType) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::PlayoutIsAvailable(bool& available) { |
+ available = true; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::RecordingIsAvailable(bool& available) { |
+ available = true; |
+ return 0; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::SetPlayoutBuffer( |
+ const AudioDeviceModule::BufferType type, |
+ uint16_t sizeMS) { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+int32_t AudioDeviceNotImplementedIOS::CPULoad(uint16_t&) const { |
+ FATAL() << "Not implemented"; |
+ return -1; |
+} |
+ |
+} // namespace webrtc |