pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. |
| 3 | * |
| 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 |
| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 | |
| 11 | #include "webrtc/modules/audio_device/dummy/audio_device_dummy.h" |
| 12 | |
| 13 | namespace webrtc { |
| 14 | |
| 15 | int32_t AudioDeviceDummy::ActiveAudioLayer( |
| 16 | AudioDeviceModule::AudioLayer& audioLayer) const { |
| 17 | return -1; |
| 18 | } |
| 19 | |
Max Morin | 84cab20 | 2016-07-01 13:35:19 +0200 | [diff] [blame] | 20 | AudioDeviceGeneric::InitStatus AudioDeviceDummy::Init() { |
| 21 | return InitStatus::OK; |
| 22 | } |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 23 | |
| 24 | int32_t AudioDeviceDummy::Terminate() { return 0; } |
| 25 | |
| 26 | bool AudioDeviceDummy::Initialized() const { return true; } |
| 27 | |
| 28 | int16_t AudioDeviceDummy::PlayoutDevices() { return -1; } |
| 29 | |
| 30 | int16_t AudioDeviceDummy::RecordingDevices() { return -1; } |
| 31 | |
| 32 | int32_t AudioDeviceDummy::PlayoutDeviceName(uint16_t index, |
| 33 | char name[kAdmMaxDeviceNameSize], |
| 34 | char guid[kAdmMaxGuidSize]) { |
| 35 | return -1; |
| 36 | } |
| 37 | |
| 38 | int32_t AudioDeviceDummy::RecordingDeviceName(uint16_t index, |
| 39 | char name[kAdmMaxDeviceNameSize], |
| 40 | char guid[kAdmMaxGuidSize]) { |
| 41 | return -1; |
| 42 | } |
| 43 | |
| 44 | int32_t AudioDeviceDummy::SetPlayoutDevice(uint16_t index) { return -1; } |
| 45 | |
| 46 | int32_t AudioDeviceDummy::SetPlayoutDevice( |
| 47 | AudioDeviceModule::WindowsDeviceType device) { |
| 48 | return -1; |
| 49 | } |
| 50 | |
| 51 | int32_t AudioDeviceDummy::SetRecordingDevice(uint16_t index) { return -1; } |
| 52 | |
| 53 | int32_t AudioDeviceDummy::SetRecordingDevice( |
| 54 | AudioDeviceModule::WindowsDeviceType device) { |
| 55 | return -1; |
| 56 | } |
| 57 | |
| 58 | int32_t AudioDeviceDummy::PlayoutIsAvailable(bool& available) { return -1; } |
| 59 | |
| 60 | int32_t AudioDeviceDummy::InitPlayout() { return -1; } |
| 61 | |
| 62 | bool AudioDeviceDummy::PlayoutIsInitialized() const { return false; } |
| 63 | |
| 64 | int32_t AudioDeviceDummy::RecordingIsAvailable(bool& available) { return -1; } |
| 65 | |
| 66 | int32_t AudioDeviceDummy::InitRecording() { return -1; } |
| 67 | |
| 68 | bool AudioDeviceDummy::RecordingIsInitialized() const { return false; } |
| 69 | |
| 70 | int32_t AudioDeviceDummy::StartPlayout() { return -1; } |
| 71 | |
maxmorin | 76cc9be | 2017-03-28 07:18:59 -0700 | [diff] [blame] | 72 | int32_t AudioDeviceDummy::StopPlayout() { return 0; } |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 73 | |
| 74 | bool AudioDeviceDummy::Playing() const { return false; } |
| 75 | |
| 76 | int32_t AudioDeviceDummy::StartRecording() { return -1; } |
| 77 | |
maxmorin | 76cc9be | 2017-03-28 07:18:59 -0700 | [diff] [blame] | 78 | int32_t AudioDeviceDummy::StopRecording() { return 0; } |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 79 | |
| 80 | bool AudioDeviceDummy::Recording() const { return false; } |
| 81 | |
| 82 | int32_t AudioDeviceDummy::SetAGC(bool enable) { return -1; } |
| 83 | |
| 84 | bool AudioDeviceDummy::AGC() const { return false; } |
| 85 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 86 | int32_t AudioDeviceDummy::InitSpeaker() { return -1; } |
| 87 | |
| 88 | bool AudioDeviceDummy::SpeakerIsInitialized() const { return false; } |
| 89 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 90 | int32_t AudioDeviceDummy::InitMicrophone() { return -1; } |
| 91 | |
| 92 | bool AudioDeviceDummy::MicrophoneIsInitialized() const { return false; } |
| 93 | |
| 94 | int32_t AudioDeviceDummy::SpeakerVolumeIsAvailable(bool& available) { |
| 95 | return -1; |
| 96 | } |
| 97 | |
| 98 | int32_t AudioDeviceDummy::SetSpeakerVolume(uint32_t volume) { return -1; } |
| 99 | |
| 100 | int32_t AudioDeviceDummy::SpeakerVolume(uint32_t& volume) const { return -1; } |
| 101 | |
| 102 | int32_t AudioDeviceDummy::MaxSpeakerVolume(uint32_t& maxVolume) const { |
| 103 | return -1; |
| 104 | } |
| 105 | |
| 106 | int32_t AudioDeviceDummy::MinSpeakerVolume(uint32_t& minVolume) const { |
| 107 | return -1; |
| 108 | } |
| 109 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 110 | int32_t AudioDeviceDummy::MicrophoneVolumeIsAvailable(bool& available) { |
| 111 | return -1; |
| 112 | } |
| 113 | |
| 114 | int32_t AudioDeviceDummy::SetMicrophoneVolume(uint32_t volume) { return -1; } |
| 115 | |
| 116 | int32_t AudioDeviceDummy::MicrophoneVolume(uint32_t& volume) const { |
| 117 | return -1; |
| 118 | } |
| 119 | |
| 120 | int32_t AudioDeviceDummy::MaxMicrophoneVolume(uint32_t& maxVolume) const { |
| 121 | return -1; |
| 122 | } |
| 123 | |
| 124 | int32_t AudioDeviceDummy::MinMicrophoneVolume(uint32_t& minVolume) const { |
| 125 | return -1; |
| 126 | } |
| 127 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 128 | int32_t AudioDeviceDummy::SpeakerMuteIsAvailable(bool& available) { return -1; } |
| 129 | |
| 130 | int32_t AudioDeviceDummy::SetSpeakerMute(bool enable) { return -1; } |
| 131 | |
| 132 | int32_t AudioDeviceDummy::SpeakerMute(bool& enabled) const { return -1; } |
| 133 | |
| 134 | int32_t AudioDeviceDummy::MicrophoneMuteIsAvailable(bool& available) { |
| 135 | return -1; |
| 136 | } |
| 137 | |
| 138 | int32_t AudioDeviceDummy::SetMicrophoneMute(bool enable) { return -1; } |
| 139 | |
| 140 | int32_t AudioDeviceDummy::MicrophoneMute(bool& enabled) const { return -1; } |
| 141 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 142 | int32_t AudioDeviceDummy::StereoPlayoutIsAvailable(bool& available) { |
| 143 | return -1; |
| 144 | } |
| 145 | int32_t AudioDeviceDummy::SetStereoPlayout(bool enable) { return -1; } |
| 146 | |
| 147 | int32_t AudioDeviceDummy::StereoPlayout(bool& enabled) const { return -1; } |
| 148 | |
| 149 | int32_t AudioDeviceDummy::StereoRecordingIsAvailable(bool& available) { |
| 150 | return -1; |
| 151 | } |
| 152 | |
| 153 | int32_t AudioDeviceDummy::SetStereoRecording(bool enable) { return -1; } |
| 154 | |
| 155 | int32_t AudioDeviceDummy::StereoRecording(bool& enabled) const { return -1; } |
| 156 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 157 | int32_t AudioDeviceDummy::PlayoutDelay(uint16_t& delayMS) const { return -1; } |
| 158 | |
| 159 | int32_t AudioDeviceDummy::RecordingDelay(uint16_t& delayMS) const { return -1; } |
| 160 | |
pbos@webrtc.org | 096515b | 2013-07-30 12:32:59 +0000 | [diff] [blame] | 161 | bool AudioDeviceDummy::PlayoutWarning() const { return false; } |
| 162 | |
| 163 | bool AudioDeviceDummy::PlayoutError() const { return false; } |
| 164 | |
| 165 | bool AudioDeviceDummy::RecordingWarning() const { return false; } |
| 166 | |
| 167 | bool AudioDeviceDummy::RecordingError() const { return false; } |
| 168 | |
| 169 | void AudioDeviceDummy::ClearPlayoutWarning() {} |
| 170 | |
| 171 | void AudioDeviceDummy::ClearPlayoutError() {} |
| 172 | |
| 173 | void AudioDeviceDummy::ClearRecordingWarning() {} |
| 174 | |
| 175 | void AudioDeviceDummy::ClearRecordingError() {} |
| 176 | |
| 177 | void AudioDeviceDummy::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer) {} |
| 178 | } // namespace webrtc |