Remove the deprecated kTraceModuleCall trace from audio device module.

Review URL: https://webrtc-codereview.appspot.com/396011

git-svn-id: http://webrtc.googlecode.com/svn/trunk@1729 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
xians@webrtc.org 2012-02-20 09:17:41 +00:00
parent 9a798d3fca
commit 20aabbb0be
19 changed files with 16 additions and 995 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -190,8 +190,6 @@ AudioDeviceAndroidJni::~AudioDeviceAndroidJni()
void AudioDeviceAndroidJni::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -211,8 +209,6 @@ void AudioDeviceAndroidJni::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceAndroidJni::ActiveAudioLayer(
AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kPlatformDefaultAudio;
@ -225,8 +221,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::ActiveAudioLayer(
WebRtc_Word32 AudioDeviceAndroidJni::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -314,8 +308,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::Init()
WebRtc_Word32 AudioDeviceAndroidJni::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -477,8 +469,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::Terminate()
bool AudioDeviceAndroidJni::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_initialized);
}
@ -489,8 +479,6 @@ bool AudioDeviceAndroidJni::Initialized() const
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
// We always assume it's available
available = true;
@ -504,8 +492,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -536,8 +522,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::InitSpeaker()
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
// We always assume it's available
available = true;
@ -551,8 +535,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -583,8 +565,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::InitMicrophone()
bool AudioDeviceAndroidJni::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _speakerIsInitialized;
}
@ -595,8 +575,6 @@ bool AudioDeviceAndroidJni::SpeakerIsInitialized() const
bool AudioDeviceAndroidJni::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _micIsInitialized;
}
@ -607,8 +585,6 @@ bool AudioDeviceAndroidJni::MicrophoneIsInitialized() const
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = true; // We assume we are always be able to set/get volume
@ -621,8 +597,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetSpeakerVolume(volume=%u)", volume);
if (!_speakerIsInitialized)
{
@ -688,8 +662,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -758,8 +730,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetWaveOutVolume(
WebRtc_UWord16 /*volumeLeft*/,
WebRtc_UWord16 /*volumeRight*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s)", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -774,8 +744,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::WaveOutVolume(
WebRtc_UWord16& /*volumeLeft*/,
WebRtc_UWord16& /*volumeRight*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -789,8 +757,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::WaveOutVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MaxSpeakerVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -811,8 +777,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MaxSpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MinSpeakerVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -833,8 +797,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MinSpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -854,8 +816,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SpeakerVolumeStepSize(
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Speaker mute not supported on Android
@ -868,8 +828,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetSpeakerMute(bool /*enable*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -882,8 +840,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetSpeakerMute(bool /*enable*/)
WebRtc_Word32 AudioDeviceAndroidJni::SpeakerMute(bool& /*enabled*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -896,8 +852,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SpeakerMute(bool& /*enabled*/) const
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Mic mute not supported on Android
@ -910,8 +864,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneMute(bool /*enable*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -924,8 +876,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneMute(bool /*enable*/)
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneMute(bool& /*enabled*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -938,8 +888,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneMute(bool& /*enabled*/) const
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Mic boost not supported on Android
@ -952,8 +900,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneBoostIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_micIsInitialized)
{
@ -978,8 +924,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_micIsInitialized)
{
@ -999,8 +943,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceAndroidJni::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Stereo recording not supported on Android
@ -1015,8 +957,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StereoRecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (enable)
{
@ -1034,8 +974,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceAndroidJni::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
enabled = false;
@ -1048,8 +986,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceAndroidJni::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Stereo playout not supported on Android
@ -1062,8 +998,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (enable)
{
@ -1081,8 +1015,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceAndroidJni::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
enabled = false;
@ -1095,8 +1027,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceAndroidJni::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetAGC(enable=%d)", enable);
_AGC = enable;
@ -1109,8 +1039,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetAGC(bool enable)
bool AudioDeviceAndroidJni::AGC() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _AGC;
}
@ -1122,8 +1050,6 @@ bool AudioDeviceAndroidJni::AGC() const
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolumeIsAvailable(
bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false; // Mic volume not supported on Android
@ -1137,8 +1063,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolumeIsAvailable(
WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneVolume(
WebRtc_UWord32 /*volume*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1152,8 +1076,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetMicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolume(
WebRtc_UWord32& /*volume*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1167,8 +1089,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MaxMicrophoneVolume(
WebRtc_UWord32& /*maxVolume*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1182,8 +1102,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MaxMicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MinMicrophoneVolume(
WebRtc_UWord32& /*minVolume*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1197,8 +1115,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MinMicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolumeStepSize(
WebRtc_UWord16& /*stepSize*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1211,8 +1127,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::MicrophoneVolumeStepSize(
WebRtc_Word16 AudioDeviceAndroidJni::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
// There is one device only
return 1;
@ -1224,8 +1138,6 @@ WebRtc_Word16 AudioDeviceAndroidJni::PlayoutDevices()
WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_playIsInitialized)
{
@ -1255,8 +1167,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutDevice(WebRtc_UWord16 index)
WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutDevice(
AudioDeviceModule::WindowsDeviceType /*device*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1272,8 +1182,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::PlayoutDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (0 != index)
{
@ -1302,8 +1210,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::RecordingDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (0 != index)
{
@ -1329,8 +1235,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::RecordingDeviceName(
WebRtc_Word16 AudioDeviceAndroidJni::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
// There is one device only
return 1;
@ -1342,8 +1246,6 @@ WebRtc_Word16 AudioDeviceAndroidJni::RecordingDevices()
WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_recIsInitialized)
{
@ -1367,8 +1269,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingDevice(WebRtc_UWord16 index)
WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingDevice(
AudioDeviceModule::WindowsDeviceType /*device*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1381,8 +1281,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingDevice(
WebRtc_Word32 AudioDeviceAndroidJni::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1406,8 +1304,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1431,8 +1327,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceAndroidJni::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1541,8 +1435,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::InitPlayout()
WebRtc_Word32 AudioDeviceAndroidJni::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1651,8 +1543,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::InitRecording()
WebRtc_Word32 AudioDeviceAndroidJni::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1738,8 +1628,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StartRecording()
WebRtc_Word32 AudioDeviceAndroidJni::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1809,8 +1697,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StopRecording()
bool AudioDeviceAndroidJni::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _recIsInitialized;
}
@ -1821,8 +1707,6 @@ bool AudioDeviceAndroidJni::RecordingIsInitialized() const
bool AudioDeviceAndroidJni::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _recording;
}
@ -1833,8 +1717,6 @@ bool AudioDeviceAndroidJni::Recording() const
bool AudioDeviceAndroidJni::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _playIsInitialized;
}
@ -1845,8 +1727,6 @@ bool AudioDeviceAndroidJni::PlayoutIsInitialized() const
WebRtc_Word32 AudioDeviceAndroidJni::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1931,8 +1811,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::StartPlayout()
WebRtc_Word32 AudioDeviceAndroidJni::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2025,8 +1903,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::RecordingDelay(
bool AudioDeviceAndroidJni::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _playing;
}
@ -2039,8 +1915,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutBuffer(
const AudioDeviceModule::BufferType /*type*/,
WebRtc_UWord16 /*sizeMS*/)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -2055,8 +1929,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::PlayoutBuffer(
AudioDeviceModule::BufferType& type,
WebRtc_UWord16& sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
type = AudioDeviceModule::kAdaptiveBufferSize;
sizeMS = _delayPlayout; // Set to current playout delay
@ -2070,8 +1942,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::PlayoutBuffer(
WebRtc_Word32 AudioDeviceAndroidJni::CPULoad(WebRtc_UWord16& /*load*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -2157,8 +2027,6 @@ void AudioDeviceAndroidJni::ClearRecordingError()
WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingSampleRate(
const WebRtc_UWord32 samplesPerSec)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s(%d)", __FUNCTION__, samplesPerSec);
if (samplesPerSec > 48000 || samplesPerSec < 8000)
{
@ -2190,8 +2058,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetRecordingSampleRate(
WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutSampleRate(
const WebRtc_UWord32 samplesPerSec)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s(%d)", __FUNCTION__, samplesPerSec);
if (samplesPerSec > 48000 || samplesPerSec < 8000)
{
@ -2222,8 +2088,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetPlayoutSampleRate(
WebRtc_Word32 AudioDeviceAndroidJni::SetLoudspeakerStatus(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s(%d)", __FUNCTION__, enable);
if (!_javaContext)
{
@ -2287,8 +2151,6 @@ WebRtc_Word32 AudioDeviceAndroidJni::SetLoudspeakerStatus(bool enable)
WebRtc_Word32 AudioDeviceAndroidJni::GetLoudspeakerStatus(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
enabled = _loudSpeakerOn;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -105,7 +105,6 @@ AudioDeviceAndroidOpenSLES::~AudioDeviceAndroidOpenSLES() {
void AudioDeviceAndroidOpenSLES::AttachAudioBuffer(
AudioDeviceBuffer* audioBuffer) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -120,7 +119,6 @@ void AudioDeviceAndroidOpenSLES::AttachAudioBuffer(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::ActiveAudioLayer(
AudioDeviceModule::AudioLayer& audioLayer) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kPlatformDefaultAudio;
@ -128,7 +126,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::ActiveAudioLayer(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::Init() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -194,7 +191,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::Init() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::Terminate() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -223,13 +219,11 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::Terminate() {
}
bool AudioDeviceAndroidOpenSLES::Initialized() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_initialized);
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerIsAvailable(bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
// We always assume it's available
available = true;
@ -238,7 +232,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerIsAvailable(bool& available) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitSpeaker() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -262,7 +255,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitSpeaker() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneIsAvailable(bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
// We always assume it's available
available = true;
@ -271,7 +263,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneIsAvailable(bool& available)
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitMicrophone() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -295,20 +286,17 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitMicrophone() {
}
bool AudioDeviceAndroidOpenSLES::SpeakerIsInitialized() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _speakerIsInitialized;
}
bool AudioDeviceAndroidOpenSLES::MicrophoneIsInitialized() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _micIsInitialized;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolumeIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true; // We assume we are always be able to set/get volume
@ -317,8 +305,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolumeIsAvailable(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetSpeakerVolume(
WebRtc_UWord32 volume) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetSpeakerVolume(volume=%u)", volume);
if (!_speakerIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -395,7 +381,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetSpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolume(
WebRtc_UWord32& volume) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
/* if (!_speakerIsInitialized)
{
@ -481,7 +466,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetWaveOutVolume(
WebRtc_UWord16 /*volumeLeft*/,
WebRtc_UWord16 /*volumeRight*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s)", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -495,7 +479,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetWaveOutVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::WaveOutVolume(
WebRtc_UWord16& /*volumeLeft*/,
WebRtc_UWord16& /*volumeRight*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -504,7 +487,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::WaveOutVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MaxSpeakerVolume(
WebRtc_UWord32& maxVolume) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -519,7 +501,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MaxSpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MinSpeakerVolume(
WebRtc_UWord32& minVolume) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -534,7 +515,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MinSpeakerVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolumeStepSize(
WebRtc_UWord16& stepSize) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -552,7 +532,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerVolumeStepSize(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerMuteIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false; // Speaker mute not supported on Android
@ -560,7 +539,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerMuteIsAvailable(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetSpeakerMute(bool /*enable*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -568,7 +546,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetSpeakerMute(bool /*enable*/) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerMute(bool& /*enabled*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -577,7 +554,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SpeakerMute(bool& /*enabled*/) const {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneMuteIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false; // Mic mute not supported on Android
@ -585,7 +561,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneMuteIsAvailable(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneMute(bool /*enable*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -594,7 +569,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneMute(bool /*enable*/) {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneMute(
bool& /*enabled*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -603,7 +577,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneMute(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneBoostIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false; // Mic boost not supported on Android
@ -611,7 +584,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneBoostIsAvailable(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneBoost(bool enable) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_micIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -629,7 +601,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneBoost(bool enable) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneBoost(bool& enabled) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_micIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -644,7 +615,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneBoost(bool& enabled) const {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoRecordingIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false; // Stereo recording not supported on Android
@ -652,7 +622,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoRecordingIsAvailable(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetStereoRecording(bool enable) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (enable) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -664,7 +633,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetStereoRecording(bool enable) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoRecording(bool& enabled) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
enabled = false;
@ -673,7 +641,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoRecording(bool& enabled) const {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoPlayoutIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false; // Stereo playout not supported on Android
@ -681,7 +648,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoPlayoutIsAvailable(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetStereoPlayout(bool enable) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (enable) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -693,7 +659,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetStereoPlayout(bool enable) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoPlayout(bool& enabled) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
enabled = false;
@ -702,8 +667,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StereoPlayout(bool& enabled) const {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetAGC(bool enable) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "SetAGC(enable=%d)",
enable);
_AGC = enable;
@ -711,14 +674,12 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetAGC(bool enable) {
}
bool AudioDeviceAndroidOpenSLES::AGC() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _AGC;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneVolumeIsAvailable(
bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
@ -727,7 +688,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneVolumeIsAvailable(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneVolume(
WebRtc_UWord32 volume) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_slEngineObject == NULL) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -763,7 +723,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetMicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneVolume(
WebRtc_UWord32& /*volume*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
/* if (_slEngineObject == NULL)
{
@ -804,13 +763,11 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MaxMicrophoneVolume(
WebRtc_UWord32& /*maxVolume*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return 0;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MinMicrophoneVolume(
WebRtc_UWord32& minVolume) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
minVolume = 0;
return 0;
@ -818,20 +775,17 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::MinMicrophoneVolume(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::MicrophoneVolumeStepSize(
WebRtc_UWord16& stepSize) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
stepSize = 1;
return 0;
}
WebRtc_Word16 AudioDeviceAndroidOpenSLES::PlayoutDevices() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return 1;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetPlayoutDevice(WebRtc_UWord16 index) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_playIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -854,7 +808,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetPlayoutDevice(WebRtc_UWord16 index)
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetPlayoutDevice(
AudioDeviceModule::WindowsDeviceType /*device*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -865,7 +818,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::PlayoutDeviceName(
WebRtc_UWord16 index,
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize]) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (0 != index) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -887,7 +839,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::RecordingDeviceName(
WebRtc_UWord16 index,
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize]) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (0 != index) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -906,14 +857,12 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::RecordingDeviceName(
}
WebRtc_Word16 AudioDeviceAndroidOpenSLES::RecordingDevices() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return 1;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetRecordingDevice(
WebRtc_UWord16 index) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_recIsInitialized) {
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -936,7 +885,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetRecordingDevice(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetRecordingDevice(
AudioDeviceModule::WindowsDeviceType /*device*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -944,7 +892,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetRecordingDevice(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::PlayoutIsAvailable(bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -962,7 +909,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::PlayoutIsAvailable(bool& available) {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::RecordingIsAvailable(bool& available) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -980,7 +926,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::RecordingIsAvailable(bool& available)
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitPlayout() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1138,7 +1083,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitPlayout() {
// ----------------------------------------------------------------------------
WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitRecording() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1342,7 +1286,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitRecording() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StartRecording() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1433,7 +1376,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StartRecording() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StopRecording() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1493,26 +1435,22 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StopRecording() {
}
bool AudioDeviceAndroidOpenSLES::RecordingIsInitialized() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _recIsInitialized;
}
bool AudioDeviceAndroidOpenSLES::Recording() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _recording;
}
bool AudioDeviceAndroidOpenSLES::PlayoutIsInitialized() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _playIsInitialized;
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StartPlayout() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1595,7 +1533,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::StartPlayout() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::StopPlayout() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1655,7 +1592,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::RecordingDelay(WebRtc_UWord16& delayMS
}
bool AudioDeviceAndroidOpenSLES::Playing() const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _playing;
}
@ -1663,7 +1599,6 @@ bool AudioDeviceAndroidOpenSLES::Playing() const {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetPlayoutBuffer(
const AudioDeviceModule::BufferType /*type*/,
WebRtc_UWord16 /*sizeMS*/) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1673,7 +1608,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetPlayoutBuffer(
WebRtc_Word32 AudioDeviceAndroidOpenSLES::PlayoutBuffer(
AudioDeviceModule::BufferType& type,
WebRtc_UWord16& sizeMS) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
type = AudioDeviceModule::kAdaptiveBufferSize;
sizeMS = _playoutDelay; // Set to current playout delay
@ -1682,7 +1616,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::PlayoutBuffer(
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::CPULoad(WebRtc_UWord16& /*load*/) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1722,8 +1655,6 @@ void AudioDeviceAndroidOpenSLES::ClearRecordingError() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetLoudspeakerStatus(bool enable) {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s(%d)",
__FUNCTION__, enable);
// if (!_javaContext)
// {
@ -1781,7 +1712,6 @@ WebRtc_Word32 AudioDeviceAndroidOpenSLES::SetLoudspeakerStatus(bool enable) {
WebRtc_Word32 AudioDeviceAndroidOpenSLES::GetLoudspeakerStatus(
bool& enabled) const {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
enabled = _loudSpeakerOn;
return 0;
@ -2001,7 +1931,6 @@ void AudioDeviceAndroidOpenSLES::UpdateRecordingDelay() {
}
WebRtc_Word32 AudioDeviceAndroidOpenSLES::InitSampleRate() {
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_Word32 res(-1);
WebRtc_Word32 numOutputs(0);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -41,8 +41,6 @@ AudioDeviceUtilityAndroid::~AudioDeviceUtilityAndroid()
WebRtc_Word32 AudioDeviceUtilityAndroid::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceStateInfo, kTraceAudioDevice, _id,
" OS info: %s", "Android");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -100,7 +100,6 @@ void AudioDeviceBuffer::SetId(WebRtc_UWord32 id)
WebRtc_Word32 AudioDeviceBuffer::RegisterAudioCallback(AudioTransport* audioCallback)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceBuffer::RegisterAudioCallback(AudioTransport=0x%x)", audioCallback);
CriticalSectionScoped lock(_critSectCb);
_ptrCbAudioTransport = audioCallback;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -77,8 +77,6 @@ namespace webrtc
AudioDeviceModule* AudioDeviceModuleImpl::Create(const WebRtc_Word32 id,
const AudioLayer audioLayer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, id,
"Create(audioLayer=%d)", (int)audioLayer);
// Create the generic ref counted (platform independent) implementation.
RefCountImpl<AudioDeviceModuleImpl>* audioDevice =
@ -454,7 +452,6 @@ AudioDeviceModuleImpl::~AudioDeviceModuleImpl()
WebRtc_Word32 AudioDeviceModuleImpl::ChangeUniqueId(const WebRtc_Word32 id)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "ChangeUniqueId(id=%d)", id);
_id = id;
return 0;
}
@ -482,7 +479,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::TimeUntilNextProcess()
WebRtc_Word32 AudioDeviceModuleImpl::Process()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "Process()");
_lastProcessTime = AudioDeviceUtility::GetTimeInMS();
@ -547,7 +543,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::Process()
WebRtc_Word32 AudioDeviceModuleImpl::ActiveAudioLayer(AudioLayer* audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
AudioLayer activeAudio;
@ -593,7 +588,6 @@ AudioDeviceModule::ErrorCode AudioDeviceModuleImpl::LastError() const
WebRtc_Word32 AudioDeviceModuleImpl::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_initialized)
return 0;
@ -621,7 +615,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::Init()
WebRtc_Word32 AudioDeviceModuleImpl::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_initialized)
return 0;
@ -641,7 +634,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::Terminate()
bool AudioDeviceModuleImpl::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WEBRTC_TRACE(kTraceStateInfo, kTraceAudioDevice, _id, "output: %d", _initialized);
return (_initialized);
@ -653,7 +645,6 @@ bool AudioDeviceModuleImpl::Initialized() const
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -675,7 +666,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->InitSpeaker());
}
@ -686,7 +676,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::InitSpeaker()
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -708,7 +697,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->InitMicrophone());
}
@ -719,7 +707,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::InitMicrophone()
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolumeIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -741,7 +728,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolumeIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetSpeakerVolume(volume=%u)", volume);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetSpeakerVolume(volume));
}
@ -752,7 +738,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolume(WebRtc_UWord32* volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord32 level(0);
@ -774,8 +759,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolume(WebRtc_UWord32* volume) const
WebRtc_Word32 AudioDeviceModuleImpl::SetWaveOutVolume(WebRtc_UWord16 volumeLeft, WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetWaveOutVolume(volumeLeft, volumeRight));
}
@ -786,7 +769,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetWaveOutVolume(WebRtc_UWord16 volumeLeft,
WebRtc_Word32 AudioDeviceModuleImpl::WaveOutVolume(WebRtc_UWord16* volumeLeft, WebRtc_UWord16* volumeRight) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 volLeft(0);
@ -812,7 +794,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::WaveOutVolume(WebRtc_UWord16* volumeLeft, W
bool AudioDeviceModuleImpl::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
bool isInitialized = _ptrAudioDevice->SpeakerIsInitialized();
@ -827,7 +808,6 @@ bool AudioDeviceModuleImpl::SpeakerIsInitialized() const
bool AudioDeviceModuleImpl::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
bool isInitialized = _ptrAudioDevice->MicrophoneIsInitialized();
@ -842,7 +822,6 @@ bool AudioDeviceModuleImpl::MicrophoneIsInitialized() const
WebRtc_Word32 AudioDeviceModuleImpl::MaxSpeakerVolume(WebRtc_UWord32* maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord32 maxVol(0);
@ -864,7 +843,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MaxSpeakerVolume(WebRtc_UWord32* maxVolume)
WebRtc_Word32 AudioDeviceModuleImpl::MinSpeakerVolume(WebRtc_UWord32* minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord32 minVol(0);
@ -886,7 +864,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MinSpeakerVolume(WebRtc_UWord32* minVolume)
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolumeStepSize(WebRtc_UWord16* stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 delta(0);
@ -909,7 +886,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerVolumeStepSize(WebRtc_UWord16* stepS
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerMuteIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -931,7 +907,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerMuteIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetSpeakerMute(enable=%d)", enable);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetSpeakerMute(enable));
}
@ -942,7 +917,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::SpeakerMute(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool muted(false);
@ -964,7 +938,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SpeakerMute(bool* enabled) const
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneMuteIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -986,7 +959,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneMuteIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetMicrophoneMute(enable=%d)", enable);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetMicrophoneMute(enable));
}
@ -997,7 +969,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneMute(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool muted(false);
@ -1019,7 +990,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneMute(bool* enabled) const
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneBoostIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1041,7 +1011,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneBoostIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetMicrophoneBoost(enable=%d)", enable);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetMicrophoneBoost(enable));
}
@ -1052,7 +1021,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneBoost(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool onOff(false);
@ -1074,7 +1042,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneBoost(bool* enabled) const
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneVolumeIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1096,7 +1063,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneVolumeIsAvailable(bool* available
WebRtc_Word32 AudioDeviceModuleImpl::SetMicrophoneVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetMicrophoneVolume(volume=%u)", volume);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetMicrophoneVolume(volume));
}
@ -1129,7 +1095,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneVolume(WebRtc_UWord32* volume) co
WebRtc_Word32 AudioDeviceModuleImpl::StereoRecordingIsAvailable(bool* available) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1151,7 +1116,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StereoRecordingIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetStereoRecording(enable=%d)", enable);
CHECK_INITIALIZED();
if (_ptrAudioDevice->RecordingIsInitialized())
@ -1182,7 +1146,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::StereoRecording(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool stereo(false);
@ -1206,15 +1169,12 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingChannel(const ChannelType chann
{
if (channel == kChannelBoth)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetRecordingChannel(kChannelBoth)");
}
else if (channel == kChannelLeft)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetRecordingChannel(kChannelLeft)");
}
else
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetRecordingChannel(kChannelRight)");
}
CHECK_INITIALIZED();
@ -1235,7 +1195,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingChannel(const ChannelType chann
WebRtc_Word32 AudioDeviceModuleImpl::RecordingChannel(ChannelType* channel) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
ChannelType chType;
@ -1249,15 +1208,12 @@ WebRtc_Word32 AudioDeviceModuleImpl::RecordingChannel(ChannelType* channel) cons
if (*channel == kChannelBoth)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "output: kChannelBoth)");
}
else if (*channel == kChannelLeft)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "output: kChannelLeft");
}
else
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "output: kChannelRight");
}
return (0);
@ -1269,7 +1225,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RecordingChannel(ChannelType* channel) cons
WebRtc_Word32 AudioDeviceModuleImpl::StereoPlayoutIsAvailable(bool* available) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1291,7 +1246,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StereoPlayoutIsAvailable(bool* available) c
WebRtc_Word32 AudioDeviceModuleImpl::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetStereoPlayout(enable=%d)", enable);
CHECK_INITIALIZED();
if (_ptrAudioDevice->PlayoutIsInitialized())
@ -1322,7 +1276,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::StereoPlayout(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool stereo(false);
@ -1344,7 +1297,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StereoPlayout(bool* enabled) const
WebRtc_Word32 AudioDeviceModuleImpl::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetAGC(enable=%d)", enable);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetAGC(enable));
}
@ -1355,7 +1307,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetAGC(bool enable)
bool AudioDeviceModuleImpl::AGC() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return (_ptrAudioDevice->AGC());
}
@ -1366,7 +1317,6 @@ bool AudioDeviceModuleImpl::AGC() const
WebRtc_Word32 AudioDeviceModuleImpl::PlayoutIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1388,7 +1338,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::PlayoutIsAvailable(bool* available)
WebRtc_Word32 AudioDeviceModuleImpl::RecordingIsAvailable(bool* available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
bool isAvailable(0);
@ -1432,7 +1381,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MaxMicrophoneVolume(WebRtc_UWord32* maxVolu
WebRtc_Word32 AudioDeviceModuleImpl::MinMicrophoneVolume(WebRtc_UWord32* minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord32 minVol(0);
@ -1454,7 +1402,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MinMicrophoneVolume(WebRtc_UWord32* minVolu
WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneVolumeStepSize(WebRtc_UWord16* stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 delta(0);
@ -1476,7 +1423,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::MicrophoneVolumeStepSize(WebRtc_UWord16* st
WebRtc_Word16 AudioDeviceModuleImpl::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 nPlayoutDevices = _ptrAudioDevice->PlayoutDevices();
@ -1491,7 +1437,6 @@ WebRtc_Word16 AudioDeviceModuleImpl::PlayoutDevices()
WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetPlayoutDevice(index));
}
@ -1504,11 +1449,9 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutDevice(WindowsDeviceType device)
{
if (device == kDefaultDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetPlayoutDevice(kDefaultDevice)");
}
else
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetPlayoutDevice(kDefaultCommunicationDevice)");
}
CHECK_INITIALIZED();
@ -1521,7 +1464,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutDevice(WindowsDeviceType device)
WebRtc_Word32 AudioDeviceModuleImpl::PlayoutDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::PlayoutDeviceName(index=%u)", index);
CHECK_INITIALIZED();
if (name == NULL)
@ -1553,7 +1495,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::PlayoutDeviceName(WebRtc_UWord16 index, Web
WebRtc_Word32 AudioDeviceModuleImpl::RecordingDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::RecordingDeviceName(index=%u)", index);
CHECK_INITIALIZED();
if (name == NULL)
@ -1585,7 +1526,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RecordingDeviceName(WebRtc_UWord16 index, W
WebRtc_Word16 AudioDeviceModuleImpl::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 nRecordingDevices = _ptrAudioDevice->RecordingDevices();
@ -1600,7 +1540,6 @@ WebRtc_Word16 AudioDeviceModuleImpl::RecordingDevices()
WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->SetRecordingDevice(index));
}
@ -1613,11 +1552,9 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingDevice(WindowsDeviceType device
{
if (device == kDefaultDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetRecordingDevice(kDefaultDevice)");
}
else
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetRecordingDevice(kDefaultCommunicationDevice)");
}
CHECK_INITIALIZED();
@ -1630,7 +1567,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingDevice(WindowsDeviceType device
WebRtc_Word32 AudioDeviceModuleImpl::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
_audioDeviceBuffer.InitPlayout();
return (_ptrAudioDevice->InitPlayout());
@ -1642,7 +1578,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::InitPlayout()
WebRtc_Word32 AudioDeviceModuleImpl::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
_audioDeviceBuffer.InitRecording();
return (_ptrAudioDevice->InitRecording());
@ -1654,7 +1589,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::InitRecording()
bool AudioDeviceModuleImpl::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return (_ptrAudioDevice->PlayoutIsInitialized());
}
@ -1665,7 +1599,6 @@ bool AudioDeviceModuleImpl::PlayoutIsInitialized() const
bool AudioDeviceModuleImpl::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return (_ptrAudioDevice->RecordingIsInitialized());
}
@ -1676,7 +1609,6 @@ bool AudioDeviceModuleImpl::RecordingIsInitialized() const
WebRtc_Word32 AudioDeviceModuleImpl::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->StartPlayout());
}
@ -1687,7 +1619,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StartPlayout()
WebRtc_Word32 AudioDeviceModuleImpl::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->StopPlayout());
}
@ -1698,7 +1629,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StopPlayout()
bool AudioDeviceModuleImpl::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return (_ptrAudioDevice->Playing());
}
@ -1709,7 +1639,6 @@ bool AudioDeviceModuleImpl::Playing() const
WebRtc_Word32 AudioDeviceModuleImpl::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->StartRecording());
}
@ -1719,7 +1648,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StartRecording()
WebRtc_Word32 AudioDeviceModuleImpl::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_ptrAudioDevice->StopRecording());
}
@ -1730,7 +1658,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StopRecording()
bool AudioDeviceModuleImpl::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return (_ptrAudioDevice->Recording());
}
@ -1741,7 +1668,6 @@ bool AudioDeviceModuleImpl::Recording() const
WebRtc_Word32 AudioDeviceModuleImpl::RegisterEventObserver(AudioDeviceObserver* eventCallback)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::RegisterEventObserver(AudioDeviceObserver=0x%x)", eventCallback);
CriticalSectionScoped lock(_critSectEventCb);
_ptrCbAudioDeviceObserver = eventCallback;
@ -1755,7 +1681,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RegisterEventObserver(AudioDeviceObserver*
WebRtc_Word32 AudioDeviceModuleImpl::RegisterAudioCallback(AudioTransport* audioCallback)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::RegisterAudioCallback(AudioTransport=0x%x)", audioCallback);
CriticalSectionScoped lock(_critSectAudioCb);
_audioDeviceBuffer.RegisterAudioCallback(audioCallback);
@ -1769,7 +1694,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RegisterAudioCallback(AudioTransport* audio
WebRtc_Word32 AudioDeviceModuleImpl::StartRawInputFileRecording(const WebRtc_Word8 pcmFileNameUTF8[kAdmMaxFileNameSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::StartRawInputFileRecording(file=%s)", pcmFileNameUTF8);
CHECK_INITIALIZED();
if (NULL == pcmFileNameUTF8)
@ -1786,7 +1710,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StartRawInputFileRecording(const WebRtc_Wor
WebRtc_Word32 AudioDeviceModuleImpl::StopRawInputFileRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_audioDeviceBuffer.StopInputFileRecording());
@ -1798,7 +1721,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StopRawInputFileRecording()
WebRtc_Word32 AudioDeviceModuleImpl::StartRawOutputFileRecording(const WebRtc_Word8 pcmFileNameUTF8[kAdmMaxFileNameSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::StartRawOutputFileRecording(file=%s)", pcmFileNameUTF8);
CHECK_INITIALIZED();
if (NULL == pcmFileNameUTF8)
@ -1815,7 +1737,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StartRawOutputFileRecording(const WebRtc_Wo
WebRtc_Word32 AudioDeviceModuleImpl::StopRawOutputFileRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return (_audioDeviceBuffer.StopOutputFileRecording());
@ -1829,7 +1750,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::StopRawOutputFileRecording()
WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutBuffer(const BufferType type, WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetPlayoutBuffer(type=%u, sizeMS=%u)", type, sizeMS);
CHECK_INITIALIZED();
if (_ptrAudioDevice->PlayoutIsInitialized())
@ -1863,7 +1783,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutBuffer(const BufferType type, Web
WebRtc_Word32 AudioDeviceModuleImpl::PlayoutBuffer(BufferType* type, WebRtc_UWord16* sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
BufferType bufType;
@ -1934,7 +1853,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RecordingDelay(WebRtc_UWord16* delayMS) con
WebRtc_Word32 AudioDeviceModuleImpl::CPULoad(WebRtc_UWord16* load) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_UWord16 cpuLoad(0);
@ -1957,7 +1875,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::CPULoad(WebRtc_UWord16* load) const
WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingSampleRate(const WebRtc_UWord32 samplesPerSec)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
if (_ptrAudioDevice->SetRecordingSampleRate(samplesPerSec) != 0)
@ -1974,7 +1891,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetRecordingSampleRate(const WebRtc_UWord32
WebRtc_Word32 AudioDeviceModuleImpl::RecordingSampleRate(WebRtc_UWord32* samplesPerSec) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_Word32 sampleRate = _audioDeviceBuffer.RecordingSampleRate();
@ -1997,7 +1913,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::RecordingSampleRate(WebRtc_UWord32* samples
WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutSampleRate(const WebRtc_UWord32 samplesPerSec)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
if (_ptrAudioDevice->SetPlayoutSampleRate(samplesPerSec) != 0)
@ -2014,7 +1929,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetPlayoutSampleRate(const WebRtc_UWord32 s
WebRtc_Word32 AudioDeviceModuleImpl::PlayoutSampleRate(WebRtc_UWord32* samplesPerSec) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
WebRtc_Word32 sampleRate = _audioDeviceBuffer.PlayoutSampleRate();
@ -2037,7 +1951,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::PlayoutSampleRate(WebRtc_UWord32* samplesPe
WebRtc_Word32 AudioDeviceModuleImpl::ResetAudioDevice()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
@ -2055,7 +1968,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::ResetAudioDevice()
WebRtc_Word32 AudioDeviceModuleImpl::SetLoudspeakerStatus(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceModuleImpl::SetLoudspeakerStatus(enable=%d)", (int)enable);
CHECK_INITIALIZED();
if (_ptrAudioDevice->SetLoudspeakerStatus(enable) != 0)
@ -2072,7 +1984,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::SetLoudspeakerStatus(bool enable)
WebRtc_Word32 AudioDeviceModuleImpl::GetLoudspeakerStatus(bool* enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
if (_ptrAudioDevice->GetLoudspeakerStatus(*enabled) != 0)
@ -2085,7 +1996,6 @@ WebRtc_Word32 AudioDeviceModuleImpl::GetLoudspeakerStatus(bool* enabled) const
int32_t AudioDeviceModuleImpl::EnableBuiltInAEC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED();
return _ptrAudioDevice->EnableBuiltInAEC(enable);
@ -2093,7 +2003,6 @@ int32_t AudioDeviceModuleImpl::EnableBuiltInAEC(bool enable)
bool AudioDeviceModuleImpl::BuiltInAECIsEnabled() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CHECK_INITIALIZED_BOOL();
return _ptrAudioDevice->BuiltInAECIsEnabled();
@ -2118,7 +2027,6 @@ AudioDeviceModuleImpl::PlatformType AudioDeviceModuleImpl::Platform() const
AudioDeviceModule::AudioLayer AudioDeviceModuleImpl::PlatformAudioLayer() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
switch (_platformAudioLayer)
{

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -121,7 +121,6 @@ AudioDeviceDummy::~AudioDeviceDummy()
void AudioDeviceDummy::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
_ptrAudioBuffer = audioBuffer;
@ -138,7 +137,6 @@ void AudioDeviceDummy::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceDummy::ActiveAudioLayer(AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kDummyAudio;
return 0;
}
@ -149,7 +147,6 @@ WebRtc_Word32 AudioDeviceDummy::ActiveAudioLayer(AudioDeviceModule::AudioLayer&
WebRtc_Word32 AudioDeviceDummy::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -240,7 +237,6 @@ WebRtc_Word32 AudioDeviceDummy::Init()
WebRtc_Word32 AudioDeviceDummy::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -308,7 +304,6 @@ WebRtc_Word32 AudioDeviceDummy::Terminate()
bool AudioDeviceDummy::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_initialized);
}
@ -318,7 +313,6 @@ bool AudioDeviceDummy::Initialized() const
WebRtc_Word32 AudioDeviceDummy::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -333,7 +327,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -353,7 +346,6 @@ WebRtc_Word32 AudioDeviceDummy::InitSpeaker()
WebRtc_Word32 AudioDeviceDummy::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -368,7 +360,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -388,7 +379,6 @@ WebRtc_Word32 AudioDeviceDummy::InitMicrophone()
bool AudioDeviceDummy::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_speakerIsInitialized);
}
@ -399,7 +389,6 @@ bool AudioDeviceDummy::SpeakerIsInitialized() const
bool AudioDeviceDummy::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_microphoneIsInitialized);
}
@ -410,7 +399,6 @@ bool AudioDeviceDummy::MicrophoneIsInitialized() const
WebRtc_Word32 AudioDeviceDummy::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -425,7 +413,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetSpeakerVolume(volume=%u)", volume);
return -1;
}
@ -436,7 +423,6 @@ WebRtc_Word32 AudioDeviceDummy::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceDummy::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -447,8 +433,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32 AudioDeviceDummy::SetWaveOutVolume(WebRtc_UWord16 volumeLeft, WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
return -1;
}
@ -459,7 +443,6 @@ WebRtc_Word32 AudioDeviceDummy::SetWaveOutVolume(WebRtc_UWord16 volumeLeft, WebR
WebRtc_Word32 AudioDeviceDummy::WaveOutVolume(WebRtc_UWord16& volumeLeft, WebRtc_UWord16& volumeRight) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -470,7 +453,6 @@ WebRtc_Word32 AudioDeviceDummy::WaveOutVolume(WebRtc_UWord16& volumeLeft, WebRtc
WebRtc_Word32 AudioDeviceDummy::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -481,7 +463,6 @@ WebRtc_Word32 AudioDeviceDummy::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) cons
WebRtc_Word32 AudioDeviceDummy::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -492,7 +473,6 @@ WebRtc_Word32 AudioDeviceDummy::MinSpeakerVolume(WebRtc_UWord32& minVolume) cons
WebRtc_Word32 AudioDeviceDummy::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -503,7 +483,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize)
WebRtc_Word32 AudioDeviceDummy::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -518,7 +497,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetSpeakerMute(enable=%u)", enable);
return -1;
}
@ -529,7 +507,6 @@ WebRtc_Word32 AudioDeviceDummy::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioDeviceDummy::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -540,7 +517,6 @@ WebRtc_Word32 AudioDeviceDummy::SpeakerMute(bool& enabled) const
WebRtc_Word32 AudioDeviceDummy::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -555,7 +531,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetMicrophoneMute(enable=%u)", enable);
return -1;
}
@ -566,7 +541,6 @@ WebRtc_Word32 AudioDeviceDummy::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioDeviceDummy::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -577,7 +551,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneMute(bool& enabled) const
WebRtc_Word32 AudioDeviceDummy::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
return 0;
@ -589,7 +562,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneBoostIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetMicrophoneBoost(enable=%u)", enable);
return -1;
}
@ -600,7 +572,6 @@ WebRtc_Word32 AudioDeviceDummy::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioDeviceDummy::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -611,7 +582,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceDummy::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
return 0;
@ -623,7 +593,6 @@ WebRtc_Word32 AudioDeviceDummy::StereoRecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetStereoRecording(enable=%u)", enable);
CriticalSectionScoped lock(_critSect);
@ -641,7 +610,6 @@ WebRtc_Word32 AudioDeviceDummy::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceDummy::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
enabled = false;
@ -654,7 +622,6 @@ WebRtc_Word32 AudioDeviceDummy::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceDummy::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
return 0;
@ -666,7 +633,6 @@ WebRtc_Word32 AudioDeviceDummy::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetStereoPlayout(enable=%u)", enable);
CriticalSectionScoped lock(_critSect);
@ -684,7 +650,6 @@ WebRtc_Word32 AudioDeviceDummy::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceDummy::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
enabled = false;
@ -697,7 +662,6 @@ WebRtc_Word32 AudioDeviceDummy::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceDummy::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetAGC(enable=%d)", enable);
return -1;
}
@ -718,7 +682,6 @@ bool AudioDeviceDummy::AGC() const
WebRtc_Word32 AudioDeviceDummy::MicrophoneVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -770,7 +733,6 @@ WebRtc_Word32 AudioDeviceDummy::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) c
WebRtc_Word32 AudioDeviceDummy::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -781,7 +743,6 @@ WebRtc_Word32 AudioDeviceDummy::MinMicrophoneVolume(WebRtc_UWord32& minVolume) c
WebRtc_Word32 AudioDeviceDummy::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -792,7 +753,6 @@ WebRtc_Word32 AudioDeviceDummy::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSiz
WebRtc_Word16 AudioDeviceDummy::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -805,7 +765,6 @@ WebRtc_Word16 AudioDeviceDummy::PlayoutDevices()
WebRtc_Word32 AudioDeviceDummy::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -835,7 +794,6 @@ WebRtc_Word32 AudioDeviceDummy::SetPlayoutDevice(AudioDeviceModule::WindowsDevic
WebRtc_Word32 AudioDeviceDummy::PlayoutDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::PlayoutDeviceName(index=%u)", index);
if (index != 0)
{
@ -858,7 +816,6 @@ WebRtc_Word32 AudioDeviceDummy::PlayoutDeviceName(WebRtc_UWord16 index, WebRtc_W
WebRtc_Word32 AudioDeviceDummy::RecordingDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::RecordingDeviceName(index=%u)", index);
if (index != 0)
{
@ -881,7 +838,6 @@ WebRtc_Word32 AudioDeviceDummy::RecordingDeviceName(WebRtc_UWord16 index, WebRtc
WebRtc_Word16 AudioDeviceDummy::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -894,7 +850,6 @@ WebRtc_Word16 AudioDeviceDummy::RecordingDevices()
WebRtc_Word32 AudioDeviceDummy::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -924,7 +879,6 @@ WebRtc_Word32 AudioDeviceDummy::SetRecordingDevice(AudioDeviceModule::WindowsDev
WebRtc_Word32 AudioDeviceDummy::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
@ -937,7 +891,6 @@ WebRtc_Word32 AudioDeviceDummy::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
@ -950,7 +903,6 @@ WebRtc_Word32 AudioDeviceDummy::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceDummy::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -981,7 +933,6 @@ WebRtc_Word32 AudioDeviceDummy::InitPlayout()
WebRtc_Word32 AudioDeviceDummy::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1013,7 +964,6 @@ WebRtc_Word32 AudioDeviceDummy::InitRecording()
WebRtc_Word32 AudioDeviceDummy::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1038,7 +988,6 @@ WebRtc_Word32 AudioDeviceDummy::StartRecording()
WebRtc_Word32 AudioDeviceDummy::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1059,7 +1008,6 @@ WebRtc_Word32 AudioDeviceDummy::StopRecording()
bool AudioDeviceDummy::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recIsInitialized);
}
@ -1069,7 +1017,6 @@ bool AudioDeviceDummy::RecordingIsInitialized() const
bool AudioDeviceDummy::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recording);
}
@ -1079,7 +1026,6 @@ bool AudioDeviceDummy::Recording() const
bool AudioDeviceDummy::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playIsInitialized);
}
@ -1090,7 +1036,6 @@ bool AudioDeviceDummy::PlayoutIsInitialized() const
WebRtc_Word32 AudioDeviceDummy::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1115,7 +1060,6 @@ WebRtc_Word32 AudioDeviceDummy::StartPlayout()
WebRtc_Word32 AudioDeviceDummy::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_playIsInitialized)
{
@ -1156,7 +1100,6 @@ WebRtc_Word32 AudioDeviceDummy::RecordingDelay(WebRtc_UWord16& delayMS) const
bool AudioDeviceDummy::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playing);
}
// ----------------------------------------------------------------------------
@ -1165,7 +1108,6 @@ bool AudioDeviceDummy::Playing() const
WebRtc_Word32 AudioDeviceDummy::SetPlayoutBuffer(const AudioDeviceModule::BufferType type, WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceDummy::SetPlayoutBuffer(type=%u, sizeMS=%u)", type, sizeMS);
CriticalSectionScoped lock(_critSect);
@ -1194,7 +1136,6 @@ WebRtc_Word32 AudioDeviceDummy::PlayoutBuffer(AudioDeviceModule::BufferType& typ
WebRtc_Word32 AudioDeviceDummy::CPULoad(WebRtc_UWord16& load) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
load = 0;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -45,8 +45,6 @@ AudioDeviceUtilityDummy::~AudioDeviceUtilityDummy()
WebRtc_Word32 AudioDeviceUtilityDummy::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceStateInfo, kTraceAudioDevice, _id,
" OS info: %s", "Dummy");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -142,8 +142,6 @@ AudioDeviceLinuxALSA::~AudioDeviceLinuxALSA()
void AudioDeviceLinuxALSA::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -161,16 +159,12 @@ void AudioDeviceLinuxALSA::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceLinuxALSA::ActiveAudioLayer(
AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kLinuxAlsaAudio;
return 0;
}
WebRtc_Word32 AudioDeviceLinuxALSA::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -201,8 +195,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::Init()
WebRtc_Word32 AudioDeviceLinuxALSA::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_initialized)
{
@ -266,15 +258,11 @@ WebRtc_Word32 AudioDeviceLinuxALSA::Terminate()
bool AudioDeviceLinuxALSA::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_initialized);
}
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -303,8 +291,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -320,8 +306,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::InitSpeaker()
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -350,8 +334,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -367,22 +349,16 @@ WebRtc_Word32 AudioDeviceLinuxALSA::InitMicrophone()
bool AudioDeviceLinuxALSA::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.SpeakerIsInitialized());
}
bool AudioDeviceLinuxALSA::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.MicrophoneIsInitialized());
}
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -411,16 +387,12 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetSpeakerVolume(volume=%u)", volume);
return (_mixerManager.SetSpeakerVolume(volume));
}
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -438,9 +410,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32 AudioDeviceLinuxALSA::SetWaveOutVolume(WebRtc_UWord16 volumeLeft,
WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -451,8 +420,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::WaveOutVolume(
WebRtc_UWord16& /*volumeLeft*/,
WebRtc_UWord16& /*volumeRight*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -462,8 +429,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::WaveOutVolume(
WebRtc_Word32 AudioDeviceLinuxALSA::MaxSpeakerVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -480,8 +445,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MaxSpeakerVolume(
WebRtc_Word32 AudioDeviceLinuxALSA::MinSpeakerVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -498,8 +461,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MinSpeakerVolume(
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -515,8 +476,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerVolumeStepSize(
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -549,15 +508,11 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetSpeakerMute(enable=%u)", enable);
return (_mixerManager.SetSpeakerMute(enable));
}
WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
@ -573,8 +528,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SpeakerMute(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -608,8 +561,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetMicrophoneMute(enable=%u)", enable);
return (_mixerManager.SetMicrophoneMute(enable));
}
@ -619,8 +570,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
@ -635,8 +584,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneMute(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -668,16 +615,12 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneBoostIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetMicrophoneBoost(enable=%u)", enable);
return (_mixerManager.SetMicrophoneBoost(enable));
}
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool onOff(0);
@ -693,8 +636,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxALSA::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -744,8 +685,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StereoRecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetStereoRecording(enable=%u)", enable);
if (enable)
_recChannels = 2;
@ -757,8 +696,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceLinuxALSA::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_recChannels == 2)
enabled = true;
@ -770,8 +707,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxALSA::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -821,8 +756,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetStereoPlayout(enable=%u)", enable);
if (enable)
_playChannels = 2;
@ -834,8 +767,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceLinuxALSA::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_playChannels == 2)
enabled = true;
@ -847,8 +778,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxALSA::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetAGC(enable=%d)", enable);
_AGC = enable;
@ -857,16 +786,12 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetAGC(bool enable)
bool AudioDeviceLinuxALSA::AGC() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _AGC;
}
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -895,8 +820,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::SetMicrophoneVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetMicrophoneVolume(volume=%u)", volume);
return (_mixerManager.SetMicrophoneVolume(volume));
@ -905,8 +828,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetMicrophoneVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -925,8 +846,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolume(WebRtc_UWord32& volume) con
WebRtc_Word32 AudioDeviceLinuxALSA::MaxMicrophoneVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -943,8 +862,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MaxMicrophoneVolume(
WebRtc_Word32 AudioDeviceLinuxALSA::MinMicrophoneVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -961,8 +878,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MinMicrophoneVolume(
WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -978,16 +893,12 @@ WebRtc_Word32 AudioDeviceLinuxALSA::MicrophoneVolumeStepSize(
WebRtc_Word16 AudioDeviceLinuxALSA::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (WebRtc_Word16)GetDevicesInfo(0, true);
}
WebRtc_Word32 AudioDeviceLinuxALSA::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -1024,8 +935,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::PlayoutDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"PlayoutDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices(PlayoutDevices());
@ -1049,8 +958,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::RecordingDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"RecordingDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices(RecordingDevices());
@ -1071,16 +978,12 @@ WebRtc_Word32 AudioDeviceLinuxALSA::RecordingDeviceName(
WebRtc_Word16 AudioDeviceLinuxALSA::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (WebRtc_Word16)GetDevicesInfo(0, false);
}
WebRtc_Word32 AudioDeviceLinuxALSA::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -1118,8 +1021,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetRecordingDevice(
WebRtc_Word32 AudioDeviceLinuxALSA::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1151,8 +1052,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1184,8 +1083,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxALSA::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
int errVal = 0;
@ -1339,8 +1236,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::InitPlayout()
WebRtc_Word32 AudioDeviceLinuxALSA::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
int errVal = 0;
@ -1512,8 +1407,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::InitRecording()
WebRtc_Word32 AudioDeviceLinuxALSA::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_recIsInitialized)
{
@ -1602,8 +1495,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StartRecording()
WebRtc_Word32 AudioDeviceLinuxALSA::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
{
CriticalSectionScoped lock(_critSect);
@ -1679,29 +1570,21 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StopRecording()
bool AudioDeviceLinuxALSA::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recIsInitialized);
}
bool AudioDeviceLinuxALSA::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recording);
}
bool AudioDeviceLinuxALSA::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playIsInitialized);
}
WebRtc_Word32 AudioDeviceLinuxALSA::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_playIsInitialized)
{
return -1;
@ -1770,8 +1653,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::StartPlayout()
WebRtc_Word32 AudioDeviceLinuxALSA::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
{
CriticalSectionScoped lock(_critSect);
@ -1846,8 +1727,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::RecordingDelay(WebRtc_UWord16& delayMS) cons
bool AudioDeviceLinuxALSA::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playing);
}
// ----------------------------------------------------------------------------
@ -1858,8 +1737,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::SetPlayoutBuffer(
const AudioDeviceModule::BufferType type,
WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetPlayoutBuffer(type=%u, sizeMS=%u)", type, sizeMS);
_playBufType = type;
if (type == AudioDeviceModule::kFixedBufferSize)
{
@ -1872,8 +1749,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::PlayoutBuffer(
AudioDeviceModule::BufferType& type,
WebRtc_UWord16& sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
type = _playBufType;
if (type == AudioDeviceModule::kFixedBufferSize)
{
@ -1889,8 +1764,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::PlayoutBuffer(
WebRtc_Word32 AudioDeviceLinuxALSA::CPULoad(WebRtc_UWord16& load) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -1948,8 +1821,6 @@ WebRtc_Word32 AudioDeviceLinuxALSA::GetDevicesInfo(
char* enumDeviceName,
const WebRtc_Word32 ednLen) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
// Device enumeration based on libjingle implementation
// by Tristan Schmelcher at Google Inc.

View File

@ -174,8 +174,6 @@ AudioDeviceLinuxPulse::~AudioDeviceLinuxPulse()
void AudioDeviceLinuxPulse::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -197,16 +195,12 @@ void AudioDeviceLinuxPulse::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceLinuxPulse::ActiveAudioLayer(
AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kLinuxPulseAudio;
return 0;
}
WebRtc_Word32 AudioDeviceLinuxPulse::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -288,8 +282,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::Init()
WebRtc_Word32 AudioDeviceLinuxPulse::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_initialized)
{
@ -357,15 +349,11 @@ WebRtc_Word32 AudioDeviceLinuxPulse::Terminate()
bool AudioDeviceLinuxPulse::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_initialized);
}
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -394,8 +382,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -441,8 +427,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::InitSpeaker()
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -471,8 +455,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -518,22 +500,16 @@ WebRtc_Word32 AudioDeviceLinuxPulse::InitMicrophone()
bool AudioDeviceLinuxPulse::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.SpeakerIsInitialized());
}
bool AudioDeviceLinuxPulse::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.MicrophoneIsInitialized());
}
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -561,16 +537,12 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetSpeakerVolume(volume=%u)", volume);
return (_mixerManager.SetSpeakerVolume(volume));
}
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -588,10 +560,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetWaveOutVolume(
WebRtc_UWord16 volumeLeft,
WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft,
volumeRight);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -602,8 +570,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::WaveOutVolume(
WebRtc_UWord16& /*volumeLeft*/,
WebRtc_UWord16& /*volumeRight*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -613,8 +579,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::WaveOutVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::MaxSpeakerVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -631,8 +595,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MaxSpeakerVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::MinSpeakerVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -649,8 +611,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MinSpeakerVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -666,8 +626,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerVolumeStepSize(
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -700,16 +658,12 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetSpeakerMute(enable=%u)", enable);
return (_mixerManager.SetSpeakerMute(enable));
}
WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
if (_mixerManager.SpeakerMute(muted) == -1)
@ -723,8 +677,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SpeakerMute(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -758,16 +710,12 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"SetMicrophoneMute(enable=%u)", enable);
return (_mixerManager.SetMicrophoneMute(enable));
}
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
if (_mixerManager.MicrophoneMute(muted) == -1)
@ -781,8 +729,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneMute(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -814,16 +760,12 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneBoostIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetMicrophoneBoost(enable=%u)", enable);
return (_mixerManager.SetMicrophoneBoost(enable));
}
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool onOff(0);
@ -839,8 +781,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxPulse::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -869,8 +809,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StereoRecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetStereoRecording(enable=%u)", enable);
#ifndef WEBRTC_PA_GTALK
if (enable)
@ -884,8 +822,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceLinuxPulse::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_recChannels == 2)
enabled = true;
@ -897,8 +833,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxPulse::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -927,8 +861,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetStereoPlayout(enable=%u)", enable);
#ifndef WEBRTC_PA_GTALK
if (enable)
@ -942,8 +874,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceLinuxPulse::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_playChannels == 2)
enabled = true;
@ -955,8 +885,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceLinuxPulse::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetAGC(enable=%d)", enable);
_AGC = enable;
@ -965,8 +893,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetAGC(bool enable)
bool AudioDeviceLinuxPulse::AGC() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _AGC;
}
@ -974,8 +900,6 @@ bool AudioDeviceLinuxPulse::AGC() const
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolumeIsAvailable(
bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -1004,9 +928,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolumeIsAvailable(
WebRtc_Word32 AudioDeviceLinuxPulse::SetMicrophoneVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetMicrophoneVolume(volume=%u)",
volume);
return (_mixerManager.SetMicrophoneVolume(volume));
}
@ -1014,8 +935,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetMicrophoneVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolume(
WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -1034,8 +953,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::MaxMicrophoneVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -1052,8 +969,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MaxMicrophoneVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::MinMicrophoneVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -1070,8 +985,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MinMicrophoneVolume(
WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -1087,8 +1000,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::MicrophoneVolumeStepSize(
WebRtc_Word16 AudioDeviceLinuxPulse::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
PaLock();
@ -1109,8 +1020,6 @@ WebRtc_Word16 AudioDeviceLinuxPulse::PlayoutDevices()
WebRtc_Word32 AudioDeviceLinuxPulse::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -1148,8 +1057,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::PlayoutDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::PlayoutDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices = PlayoutDevices();
@ -1192,8 +1099,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::RecordingDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::RecordingDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices(RecordingDevices());
@ -1233,8 +1138,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::RecordingDeviceName(
WebRtc_Word16 AudioDeviceLinuxPulse::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
PaLock();
@ -1255,8 +1158,6 @@ WebRtc_Word16 AudioDeviceLinuxPulse::RecordingDevices()
WebRtc_Word32 AudioDeviceLinuxPulse::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -1291,8 +1192,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetRecordingDevice(
WebRtc_Word32 AudioDeviceLinuxPulse::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1312,8 +1211,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = false;
@ -1333,8 +1230,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceLinuxPulse::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1461,8 +1356,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::InitPlayout()
WebRtc_Word32 AudioDeviceLinuxPulse::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1580,8 +1473,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::InitRecording()
WebRtc_Word32 AudioDeviceLinuxPulse::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_recIsInitialized)
{
@ -1610,8 +1501,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StartRecording()
if (_recording)
{
// the recording state is set by the audio thread after recording has started
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
" recording is now active");
} else
{
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -1624,8 +1513,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StartRecording()
WebRtc_Word32 AudioDeviceLinuxPulse::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1689,29 +1576,21 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StopRecording()
bool AudioDeviceLinuxPulse::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recIsInitialized);
}
bool AudioDeviceLinuxPulse::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recording);
}
bool AudioDeviceLinuxPulse::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playIsInitialized);
}
WebRtc_Word32 AudioDeviceLinuxPulse::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_playIsInitialized)
{
@ -1740,8 +1619,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StartPlayout()
if (_playing)
{
// the playing state is set by the audio thread after playout has started
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
" playing is now active");
} else
{
WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id,
@ -1754,8 +1631,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::StartPlayout()
WebRtc_Word32 AudioDeviceLinuxPulse::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1833,8 +1708,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::RecordingDelay(WebRtc_UWord16& delayMS) con
bool AudioDeviceLinuxPulse::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playing);
}
@ -1842,9 +1715,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::SetPlayoutBuffer(
const AudioDeviceModule::BufferType type,
WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceLinuxPulse::SetPlayoutBuffer(type=%u, sizeMS=%u)",
type, sizeMS);
if (type != AudioDeviceModule::kFixedBufferSize)
{
@ -1863,8 +1733,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::PlayoutBuffer(
AudioDeviceModule::BufferType& type,
WebRtc_UWord16& sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
type = _playBufType;
sizeMS = _playBufDelayFixed;
@ -1874,8 +1742,6 @@ WebRtc_Word32 AudioDeviceLinuxPulse::PlayoutBuffer(
WebRtc_Word32 AudioDeviceLinuxPulse::CPULoad(WebRtc_UWord16& /*load*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -44,8 +44,6 @@ AudioDeviceUtilityLinux::~AudioDeviceUtilityLinux()
WebRtc_Word32 AudioDeviceUtilityLinux::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceStateInfo, kTraceAudioDevice, _id,
" OS info: %s", "Linux");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -404,8 +404,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetSpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SpeakerVolume(
WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -440,8 +438,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MaxSpeakerVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -476,8 +472,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MaxSpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MinSpeakerVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -519,7 +513,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MinSpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMaxSpeakerVolume(
WebRtc_UWord32 maxVolume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -561,7 +554,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MinSpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMinSpeakerVolume(
WebRtc_UWord32 minVolume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -600,8 +592,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MinSpeakerVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SpeakerVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -688,8 +678,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxALSA::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputMixerElement == NULL)
{
@ -787,8 +775,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxALSA::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -878,8 +864,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxALSA::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{
@ -950,7 +934,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMaxMicrophoneVolume(
WebRtc_UWord32 maxVolume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -992,7 +975,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMinMicrophoneVolume(
WebRtc_UWord32 minVolume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -1033,8 +1015,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::SetMicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MicrophoneVolume(
WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -1070,8 +1050,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MaxMicrophoneVolume(
WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -1113,8 +1091,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MaxMicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MinMicrophoneVolume(
WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerElement == NULL)
{
@ -1148,8 +1124,6 @@ WebRtc_Word32 AudioMixerManagerLinuxALSA::MinMicrophoneVolume(
WebRtc_Word32 AudioMixerManagerLinuxALSA::MicrophoneVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -303,8 +303,6 @@ WebRtc_Word32 AudioMixerManagerLinuxPulse::SetSpeakerVolume(
WebRtc_Word32
AudioMixerManagerLinuxPulse::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paOutputDeviceIndex == -1)
{
@ -356,8 +354,6 @@ AudioMixerManagerLinuxPulse::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32
AudioMixerManagerLinuxPulse::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paOutputDeviceIndex == -1)
{
@ -376,8 +372,6 @@ AudioMixerManagerLinuxPulse::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
WebRtc_Word32
AudioMixerManagerLinuxPulse::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paOutputDeviceIndex == -1)
{
@ -394,8 +388,6 @@ AudioMixerManagerLinuxPulse::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
WebRtc_Word32
AudioMixerManagerLinuxPulse::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paOutputDeviceIndex == -1)
{
@ -509,8 +501,6 @@ WebRtc_Word32 AudioMixerManagerLinuxPulse::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxPulse::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paOutputDeviceIndex == -1)
{
@ -751,8 +741,6 @@ WebRtc_Word32 AudioMixerManagerLinuxPulse::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxPulse::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{
@ -857,8 +845,6 @@ WebRtc_Word32 AudioMixerManagerLinuxPulse::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioMixerManagerLinuxPulse::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{
@ -990,8 +976,6 @@ AudioMixerManagerLinuxPulse::SetMicrophoneVolume(WebRtc_UWord32 volume)
WebRtc_Word32
AudioMixerManagerLinuxPulse::MicrophoneVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{
@ -1048,8 +1032,6 @@ AudioMixerManagerLinuxPulse::MicrophoneVolume(WebRtc_UWord32& volume) const
WebRtc_Word32
AudioMixerManagerLinuxPulse::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{
@ -1069,8 +1051,6 @@ AudioMixerManagerLinuxPulse::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) cons
WebRtc_Word32
AudioMixerManagerLinuxPulse::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{
@ -1087,8 +1067,6 @@ AudioMixerManagerLinuxPulse::MinMicrophoneVolume(WebRtc_UWord32& minVolume) cons
WebRtc_Word32 AudioMixerManagerLinuxPulse::MicrophoneVolumeStepSize(
WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_paInputDeviceIndex == -1)
{

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -242,8 +242,6 @@ AudioDeviceMac::~AudioDeviceMac()
void AudioDeviceMac::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -259,16 +257,12 @@ void AudioDeviceMac::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceMac::ActiveAudioLayer(
AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kPlatformDefaultAudio;
return 0;
}
WebRtc_Word32 AudioDeviceMac::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -432,8 +426,6 @@ WebRtc_Word32 AudioDeviceMac::Init()
WebRtc_Word32 AudioDeviceMac::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (!_initialized)
{
@ -487,15 +479,11 @@ WebRtc_Word32 AudioDeviceMac::Terminate()
bool AudioDeviceMac::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_initialized);
}
WebRtc_Word32 AudioDeviceMac::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -524,8 +512,6 @@ WebRtc_Word32 AudioDeviceMac::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -557,8 +543,6 @@ WebRtc_Word32 AudioDeviceMac::InitSpeaker()
WebRtc_Word32 AudioDeviceMac::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -588,8 +572,6 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -621,22 +603,16 @@ WebRtc_Word32 AudioDeviceMac::InitMicrophone()
bool AudioDeviceMac::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.SpeakerIsInitialized());
}
bool AudioDeviceMac::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_mixerManager.MicrophoneIsInitialized());
}
WebRtc_Word32 AudioDeviceMac::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -667,16 +643,12 @@ WebRtc_Word32 AudioDeviceMac::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetSpeakerVolume(volume=%u)", volume);
return (_mixerManager.SetSpeakerVolume(volume));
}
WebRtc_Word32 AudioDeviceMac::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -692,12 +664,6 @@ WebRtc_Word32 AudioDeviceMac::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32 AudioDeviceMac::SetWaveOutVolume(WebRtc_UWord16 volumeLeft,
WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(
kTraceModuleCall,
kTraceAudioDevice,
_id,
"AudioDeviceMac::SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -708,8 +674,6 @@ WebRtc_Word32
AudioDeviceMac::WaveOutVolume(WebRtc_UWord16& /*volumeLeft*/,
WebRtc_UWord16& /*volumeRight*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");
@ -718,8 +682,6 @@ AudioDeviceMac::WaveOutVolume(WebRtc_UWord16& /*volumeLeft*/,
WebRtc_Word32 AudioDeviceMac::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -734,8 +696,6 @@ WebRtc_Word32 AudioDeviceMac::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
WebRtc_Word32 AudioDeviceMac::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -751,8 +711,6 @@ WebRtc_Word32 AudioDeviceMac::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
WebRtc_Word32
AudioDeviceMac::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -767,8 +725,6 @@ AudioDeviceMac::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
WebRtc_Word32 AudioDeviceMac::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -803,15 +759,11 @@ WebRtc_Word32 AudioDeviceMac::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetSpeakerMute(enable=%u)", enable);
return (_mixerManager.SetSpeakerMute(enable));
}
WebRtc_Word32 AudioDeviceMac::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
@ -826,8 +778,6 @@ WebRtc_Word32 AudioDeviceMac::SpeakerMute(bool& enabled) const
WebRtc_Word32 AudioDeviceMac::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -861,15 +811,11 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceWindowsWave::SetMicrophoneMute(enable=%u)", enable);
return (_mixerManager.SetMicrophoneMute(enable));
}
WebRtc_Word32 AudioDeviceMac::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool muted(0);
@ -884,8 +830,6 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneMute(bool& enabled) const
WebRtc_Word32 AudioDeviceMac::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -919,16 +863,12 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneBoostIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetMicrophoneBoost(enable=%u)", enable);
return (_mixerManager.SetMicrophoneBoost(enable));
}
WebRtc_Word32 AudioDeviceMac::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool onOff(0);
@ -943,8 +883,6 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceMac::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -973,8 +911,6 @@ WebRtc_Word32 AudioDeviceMac::StereoRecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetStereoRecording(enable=%u)", enable);
if (enable)
_recChannels = 2;
@ -986,8 +922,6 @@ WebRtc_Word32 AudioDeviceMac::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceMac::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_recChannels == 2)
enabled = true;
@ -999,8 +933,6 @@ WebRtc_Word32 AudioDeviceMac::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceMac::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool isAvailable(false);
bool wasInitialized = _mixerManager.SpeakerIsInitialized();
@ -1029,8 +961,6 @@ WebRtc_Word32 AudioDeviceMac::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetStereoPlayout(enable=%u)", enable);
if (enable)
_playChannels = 2;
@ -1042,8 +972,6 @@ WebRtc_Word32 AudioDeviceMac::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceMac::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_playChannels == 2)
enabled = true;
@ -1055,8 +983,6 @@ WebRtc_Word32 AudioDeviceMac::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceMac::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetAGC(enable=%d)", enable);
_AGC = enable;
@ -1065,16 +991,12 @@ WebRtc_Word32 AudioDeviceMac::SetAGC(bool enable)
bool AudioDeviceMac::AGC() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return _AGC;
}
WebRtc_Word32 AudioDeviceMac::MicrophoneVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
bool wasInitialized = _mixerManager.MicrophoneIsInitialized();
@ -1106,16 +1028,12 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::SetMicrophoneVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetMicrophoneVolume(volume=%u)", volume);
return (_mixerManager.SetMicrophoneVolume(volume));
}
WebRtc_Word32 AudioDeviceMac::MicrophoneVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -1133,8 +1051,6 @@ WebRtc_Word32 AudioDeviceMac::MicrophoneVolume(WebRtc_UWord32& volume) const
WebRtc_Word32
AudioDeviceMac::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -1150,8 +1066,6 @@ AudioDeviceMac::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) const
WebRtc_Word32
AudioDeviceMac::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -1167,8 +1081,6 @@ AudioDeviceMac::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
WebRtc_Word32
AudioDeviceMac::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -1183,8 +1095,6 @@ AudioDeviceMac::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
WebRtc_Word16 AudioDeviceMac::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
AudioDeviceID playDevices[MaxNumberDevices];
return GetNumberDevices(kAudioDevicePropertyScopeOutput, playDevices,
@ -1193,8 +1103,6 @@ WebRtc_Word16 AudioDeviceMac::PlayoutDevices()
WebRtc_Word32 AudioDeviceMac::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -1234,8 +1142,6 @@ WebRtc_Word32 AudioDeviceMac::PlayoutDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::PlayoutDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices(PlayoutDevices());
@ -1259,8 +1165,6 @@ WebRtc_Word32 AudioDeviceMac::RecordingDeviceName(
WebRtc_Word8 name[kAdmMaxDeviceNameSize],
WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::RecordingDeviceName(index=%u)", index);
const WebRtc_UWord16 nDevices(RecordingDevices());
@ -1281,8 +1185,6 @@ WebRtc_Word32 AudioDeviceMac::RecordingDeviceName(
WebRtc_Word16 AudioDeviceMac::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
AudioDeviceID recDevices[MaxNumberDevices];
return GetNumberDevices(kAudioDevicePropertyScopeInput, recDevices,
@ -1291,8 +1193,6 @@ WebRtc_Word16 AudioDeviceMac::RecordingDevices()
WebRtc_Word32 AudioDeviceMac::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -1330,8 +1230,6 @@ AudioDeviceMac::SetRecordingDevice(AudioDeviceModule::WindowsDeviceType /*device
WebRtc_Word32 AudioDeviceMac::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = true;
@ -1360,8 +1258,6 @@ WebRtc_Word32 AudioDeviceMac::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
available = true;
@ -1390,8 +1286,6 @@ WebRtc_Word32 AudioDeviceMac::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceMac::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1655,8 +1549,6 @@ WebRtc_Word32 AudioDeviceMac::InitPlayout()
WebRtc_Word32 AudioDeviceMac::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1873,8 +1765,6 @@ WebRtc_Word32 AudioDeviceMac::InitRecording()
WebRtc_Word32 AudioDeviceMac::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1919,8 +1809,6 @@ WebRtc_Word32 AudioDeviceMac::StartRecording()
WebRtc_Word32 AudioDeviceMac::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2029,29 +1917,21 @@ WebRtc_Word32 AudioDeviceMac::StopRecording()
bool AudioDeviceMac::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recIsInitialized);
}
bool AudioDeviceMac::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_recording);
}
bool AudioDeviceMac::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playIsInitialized);
}
WebRtc_Word32 AudioDeviceMac::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2085,8 +1965,6 @@ WebRtc_Word32 AudioDeviceMac::StartPlayout()
WebRtc_Word32 AudioDeviceMac::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2193,8 +2071,6 @@ WebRtc_Word32 AudioDeviceMac::RecordingDelay(WebRtc_UWord16& delayMS) const
bool AudioDeviceMac::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
return (_playing);
}
@ -2202,9 +2078,6 @@ WebRtc_Word32 AudioDeviceMac::SetPlayoutBuffer(
const AudioDeviceModule::BufferType type,
WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"AudioDeviceMac::SetPlayoutBuffer(type=%u, sizeMS=%u)", type,
sizeMS);
if (type != AudioDeviceModule::kFixedBufferSize)
{
@ -2222,8 +2095,6 @@ WebRtc_Word32 AudioDeviceMac::PlayoutBuffer(
AudioDeviceModule::BufferType& type,
WebRtc_UWord16& sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
type = _playBufType;
sizeMS = _playBufDelayFixed;
@ -2234,8 +2105,6 @@ WebRtc_Word32 AudioDeviceMac::PlayoutBuffer(
// Not implemented for Mac.
WebRtc_Word32 AudioDeviceMac::CPULoad(WebRtc_UWord16& /*load*/) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceWarning, kTraceAudioDevice, _id,
" API call not supported on this platform");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -44,8 +44,6 @@ AudioDeviceUtilityMac::~AudioDeviceUtilityMac()
WebRtc_Word32 AudioDeviceUtilityMac::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
WEBRTC_TRACE(kTraceStateInfo, kTraceAudioDevice, _id,
" OS info: %s", "OS X");

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -301,8 +301,6 @@ WebRtc_Word32 AudioMixerManagerMac::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioMixerManagerMac::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputDeviceID == kAudioObjectUnknown)
{
@ -374,8 +372,6 @@ WebRtc_Word32 AudioMixerManagerMac::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32
AudioMixerManagerMac::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputDeviceID == kAudioObjectUnknown)
{
@ -394,8 +390,6 @@ AudioMixerManagerMac::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
WebRtc_Word32
AudioMixerManagerMac::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputDeviceID == kAudioObjectUnknown)
{
@ -414,8 +408,6 @@ AudioMixerManagerMac::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
WebRtc_Word32
AudioMixerManagerMac::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputDeviceID == kAudioObjectUnknown)
{
@ -585,8 +577,6 @@ WebRtc_Word32 AudioMixerManagerMac::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioMixerManagerMac::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_outputDeviceID == kAudioObjectUnknown)
{
@ -787,8 +777,6 @@ WebRtc_Word32 AudioMixerManagerMac::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioMixerManagerMac::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{
@ -900,8 +888,6 @@ WebRtc_Word32 AudioMixerManagerMac::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioMixerManagerMac::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{
@ -1031,8 +1017,6 @@ WebRtc_Word32 AudioMixerManagerMac::SetMicrophoneVolume(WebRtc_UWord32 volume)
WebRtc_Word32
AudioMixerManagerMac::MicrophoneVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{
@ -1106,8 +1090,6 @@ AudioMixerManagerMac::MicrophoneVolume(WebRtc_UWord32& volume) const
WebRtc_Word32
AudioMixerManagerMac::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{
@ -1126,8 +1108,6 @@ AudioMixerManagerMac::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume) const
WebRtc_Word32
AudioMixerManagerMac::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{
@ -1146,8 +1126,6 @@ AudioMixerManagerMac::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
WebRtc_Word32
AudioMixerManagerMac::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id,
"%s", __FUNCTION__);
if (_inputDeviceID == kAudioObjectUnknown)
{

View File

@ -653,7 +653,6 @@ AudioDeviceWindowsCore::~AudioDeviceWindowsCore()
void AudioDeviceWindowsCore::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
_ptrAudioBuffer = audioBuffer;
@ -672,7 +671,6 @@ void AudioDeviceWindowsCore::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceWindowsCore::ActiveAudioLayer(AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kWindowsCoreAudio;
return 0;
}
@ -683,7 +681,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::ActiveAudioLayer(AudioDeviceModule::AudioL
WebRtc_Word32 AudioDeviceWindowsCore::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -715,7 +712,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::Init()
WebRtc_Word32 AudioDeviceWindowsCore::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -749,7 +745,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::Terminate()
bool AudioDeviceWindowsCore::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_initialized);
}
@ -759,7 +754,6 @@ bool AudioDeviceWindowsCore::Initialized() const
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -779,7 +773,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsCore::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -862,7 +855,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::InitSpeaker()
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -882,7 +874,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsCore::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -952,7 +943,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::InitMicrophone()
bool AudioDeviceWindowsCore::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_speakerIsInitialized);
}
@ -963,7 +953,6 @@ bool AudioDeviceWindowsCore::SpeakerIsInitialized() const
bool AudioDeviceWindowsCore::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_microphoneIsInitialized);
}
@ -974,7 +963,6 @@ bool AudioDeviceWindowsCore::MicrophoneIsInitialized() const
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1019,7 +1007,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetSpeakerVolume(volume=%u)", volume);
{
CriticalSectionScoped lock(_critSect);
@ -1063,7 +1050,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
{
CriticalSectionScoped lock(_critSect);
@ -1103,8 +1089,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SetWaveOutVolume(WebRtc_UWord16 volumeLeft, WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
return -1;
}
@ -1114,7 +1098,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetWaveOutVolume(WebRtc_UWord16 volumeLeft
WebRtc_Word32 AudioDeviceWindowsCore::WaveOutVolume(WebRtc_UWord16& volumeLeft, WebRtc_UWord16& volumeRight) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return -1;
}
@ -1129,7 +1112,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::WaveOutVolume(WebRtc_UWord16& volumeLeft,
WebRtc_Word32 AudioDeviceWindowsCore::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -1147,7 +1129,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MaxSpeakerVolume(WebRtc_UWord32& maxVolume
WebRtc_Word32 AudioDeviceWindowsCore::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -1165,7 +1146,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MinSpeakerVolume(WebRtc_UWord32& minVolume
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -1183,7 +1163,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SpeakerVolumeStepSize(WebRtc_UWord16& step
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1223,7 +1202,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetSpeakerMute(enable=%u)", enable);
CriticalSectionScoped lock(_critSect);
@ -1264,7 +1242,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_speakerIsInitialized)
{
@ -1305,7 +1282,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1343,7 +1319,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetMicrophoneMute(enable=%u)", enable);
if (!_microphoneIsInitialized)
{
@ -1381,7 +1356,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_microphoneIsInitialized)
{
@ -1416,7 +1390,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
return 0;
@ -1428,7 +1401,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneBoostIsAvailable(bool& available
WebRtc_Word32 AudioDeviceWindowsCore::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetMicrophoneBoost(enable=%u)", enable);
if (!_microphoneIsInitialized)
{
@ -1444,7 +1416,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_microphoneIsInitialized)
{
@ -1460,7 +1431,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsCore::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
return 0;
@ -1472,7 +1442,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StereoRecordingIsAvailable(bool& available
WebRtc_Word32 AudioDeviceWindowsCore::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetStereoRecording(enable=%u)", enable);
CriticalSectionScoped lock(_critSect);
@ -1498,7 +1467,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceWindowsCore::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_recChannels == 2)
enabled = true;
@ -1514,7 +1482,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsCore::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
return 0;
@ -1526,7 +1493,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsCore::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetStereoPlayout(enable=%u)", enable);
CriticalSectionScoped lock(_critSect);
@ -1552,7 +1518,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceWindowsCore::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_playChannels == 2)
enabled = true;
@ -1568,7 +1533,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsCore::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetAGC(enable=%d)", enable);
CriticalSectionScoped lock(_critSect);
_AGC = enable;
return 0;
@ -1590,7 +1554,6 @@ bool AudioDeviceWindowsCore::AGC() const
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1732,7 +1695,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MaxMicrophoneVolume(WebRtc_UWord32& maxVol
WebRtc_Word32 AudioDeviceWindowsCore::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_microphoneIsInitialized)
{
@ -1750,7 +1712,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MinMicrophoneVolume(WebRtc_UWord32& minVol
WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_microphoneIsInitialized)
{
@ -1768,7 +1729,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::MicrophoneVolumeStepSize(WebRtc_UWord16& s
WebRtc_Word16 AudioDeviceWindowsCore::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1786,7 +1746,6 @@ WebRtc_Word16 AudioDeviceWindowsCore::PlayoutDevices()
WebRtc_Word32 AudioDeviceWindowsCore::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -1851,12 +1810,10 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetPlayoutDevice(AudioDeviceModule::Window
if (device == AudioDeviceModule::kDefaultDevice)
{
role = eConsole;
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetPlayoutDevice(kDefaultDevice)");
}
else if (device == AudioDeviceModule::kDefaultCommunicationDevice)
{
role = eCommunications;
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetPlayoutDevice(kDefaultCommunicationDevice)");
}
CriticalSectionScoped lock(_critSect);
@ -1902,7 +1859,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetPlayoutDevice(AudioDeviceModule::Window
WebRtc_Word32 AudioDeviceWindowsCore::PlayoutDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::PlayoutDeviceName(index=%u)", index);
bool defaultCommunicationDevice(false);
const WebRtc_Word16 nDevices(PlayoutDevices()); // also updates the list of devices
@ -1981,7 +1937,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::PlayoutDeviceName(WebRtc_UWord16 index, We
WebRtc_Word32 AudioDeviceWindowsCore::RecordingDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::RecordingDeviceName(index=%u)", index);
bool defaultCommunicationDevice(false);
const WebRtc_Word16 nDevices(RecordingDevices()); // also updates the list of devices
@ -2060,7 +2015,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::RecordingDeviceName(WebRtc_UWord16 index,
WebRtc_Word16 AudioDeviceWindowsCore::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2078,7 +2032,6 @@ WebRtc_Word16 AudioDeviceWindowsCore::RecordingDevices()
WebRtc_Word32 AudioDeviceWindowsCore::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -2143,12 +2096,10 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetRecordingDevice(AudioDeviceModule::Wind
if (device == AudioDeviceModule::kDefaultDevice)
{
role = eConsole;
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetRecordingDevice(kDefaultDevice)");
}
else if (device == AudioDeviceModule::kDefaultCommunicationDevice)
{
role = eCommunications;
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetRecordingDevice(kDefaultCommunicationDevice)");
}
CriticalSectionScoped lock(_critSect);
@ -2194,7 +2145,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::SetRecordingDevice(AudioDeviceModule::Wind
WebRtc_Word32 AudioDeviceWindowsCore::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -2218,7 +2168,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsCore::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -2242,7 +2191,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsCore::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2585,7 +2533,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::InitRecordingDMO()
WebRtc_Word32 AudioDeviceWindowsCore::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2817,7 +2764,6 @@ Exit:
WebRtc_Word32 AudioDeviceWindowsCore::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_recIsInitialized)
{
@ -2925,7 +2871,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StartRecording()
WebRtc_Word32 AudioDeviceWindowsCore::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_Word32 err = 0;
if (!_recIsInitialized)
@ -3042,7 +2987,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StopRecording()
bool AudioDeviceWindowsCore::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recIsInitialized);
}
@ -3052,7 +2996,6 @@ bool AudioDeviceWindowsCore::RecordingIsInitialized() const
bool AudioDeviceWindowsCore::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recording);
}
@ -3062,7 +3005,6 @@ bool AudioDeviceWindowsCore::Recording() const
bool AudioDeviceWindowsCore::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playIsInitialized);
}
@ -3073,7 +3015,6 @@ bool AudioDeviceWindowsCore::PlayoutIsInitialized() const
WebRtc_Word32 AudioDeviceWindowsCore::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_playIsInitialized)
{
@ -3135,7 +3076,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::StartPlayout()
WebRtc_Word32 AudioDeviceWindowsCore::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_playIsInitialized)
{
@ -3240,7 +3180,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::RecordingDelay(WebRtc_UWord16& delayMS) co
bool AudioDeviceWindowsCore::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playing);
}
// ----------------------------------------------------------------------------
@ -3249,7 +3188,6 @@ bool AudioDeviceWindowsCore::Playing() const
WebRtc_Word32 AudioDeviceWindowsCore::SetPlayoutBuffer(const AudioDeviceModule::BufferType type, WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsCore::SetPlayoutBuffer(type=%u, sizeMS=%u)", type, sizeMS);
CriticalSectionScoped lock(_critSect);
@ -3294,7 +3232,6 @@ WebRtc_Word32 AudioDeviceWindowsCore::PlayoutBuffer(AudioDeviceModule::BufferTyp
WebRtc_Word32 AudioDeviceWindowsCore::CPULoad(WebRtc_UWord16& load) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
load = static_cast<WebRtc_UWord16> (100*_avgCPULoad);
@ -3489,7 +3426,6 @@ DWORD AudioDeviceWindowsCore::DoSetCaptureVolumeThread()
DWORD AudioDeviceWindowsCore::DoRenderThread()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool keepPlaying = true;
HANDLE waitArray[2] = {_hShutdownRenderEvent, _hRenderSamplesReadyEvent};
@ -3970,7 +3906,6 @@ DWORD AudioDeviceWindowsCore::DoCaptureThreadPollDMO()
DWORD AudioDeviceWindowsCore::DoCaptureThread()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool keepRecording = true;
HANDLE waitArray[2] = {_hShutdownCaptureEvent, _hCaptureSamplesReadyEvent};
@ -4275,7 +4210,6 @@ Exit:
int32_t AudioDeviceWindowsCore::EnableBuiltInAEC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_recIsInitialized)
{
@ -4297,7 +4231,6 @@ int32_t AudioDeviceWindowsCore::EnableBuiltInAEC(bool enable)
bool AudioDeviceWindowsCore::BuiltInAECIsEnabled() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return _builtInAecEnabled;
}

View File

@ -68,7 +68,6 @@ AudioDeviceUtilityWindows::~AudioDeviceUtilityWindows()
WebRtc_Word32 AudioDeviceUtilityWindows::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
TCHAR szOS[STRING_MAX_SIZE];

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -173,7 +173,6 @@ AudioDeviceWindowsWave::~AudioDeviceWindowsWave()
void AudioDeviceWindowsWave::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -192,7 +191,6 @@ void AudioDeviceWindowsWave::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer)
WebRtc_Word32 AudioDeviceWindowsWave::ActiveAudioLayer(AudioDeviceModule::AudioLayer& audioLayer) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
audioLayer = AudioDeviceModule::kWindowsWaveAudio;
return 0;
}
@ -203,7 +201,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::ActiveAudioLayer(AudioDeviceModule::AudioL
WebRtc_Word32 AudioDeviceWindowsWave::Init()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -317,7 +314,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::Init()
WebRtc_Word32 AudioDeviceWindowsWave::Terminate()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_initialized)
{
@ -490,7 +486,6 @@ DWORD AudioDeviceWindowsWave::DoSetCaptureVolumeThread()
bool AudioDeviceWindowsWave::Initialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_initialized);
}
@ -500,7 +495,6 @@ bool AudioDeviceWindowsWave::Initialized() const
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
// Enumerate all avaliable speakers and make an attempt to open up the
// output mixer corresponding to the currently selected output device.
@ -528,7 +522,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::InitSpeaker()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -567,7 +560,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::InitSpeaker()
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
// Enumerate all avaliable microphones and make an attempt to open up the
// input mixer corresponding to the currently selected output device.
@ -595,7 +587,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::InitMicrophone()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -650,7 +641,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::InitMicrophone()
bool AudioDeviceWindowsWave::SpeakerIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_mixerManager.SpeakerIsInitialized());
}
@ -660,7 +650,6 @@ bool AudioDeviceWindowsWave::SpeakerIsInitialized() const
bool AudioDeviceWindowsWave::MicrophoneIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_mixerManager.MicrophoneIsInitialized());
}
@ -670,7 +659,6 @@ bool AudioDeviceWindowsWave::MicrophoneIsInitialized() const
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool isAvailable(false);
@ -702,7 +690,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolumeIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::SetSpeakerVolume(WebRtc_UWord32 volume)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetSpeakerVolume(volume=%u)", volume);
return (_mixerManager.SetSpeakerVolume(volume));
}
@ -713,7 +700,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord32 level(0);
@ -745,8 +731,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolume(WebRtc_UWord32& volume) cons
WebRtc_Word32 AudioDeviceWindowsWave::SetWaveOutVolume(WebRtc_UWord16 volumeLeft, WebRtc_UWord16 volumeRight)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetWaveOutVolume(volumeLeft=%u, volumeRight=%u)",
volumeLeft, volumeRight);
MMRESULT res(0);
WAVEOUTCAPS caps;
@ -811,7 +795,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetWaveOutVolume(WebRtc_UWord16 volumeLeft
WebRtc_Word32 AudioDeviceWindowsWave::WaveOutVolume(WebRtc_UWord16& volumeLeft, WebRtc_UWord16& volumeRight) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
MMRESULT res(0);
WAVEOUTCAPS caps;
@ -869,7 +852,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::WaveOutVolume(WebRtc_UWord16& volumeLeft,
WebRtc_Word32 AudioDeviceWindowsWave::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord32 maxVol(0);
@ -888,7 +870,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MaxSpeakerVolume(WebRtc_UWord32& maxVolume
WebRtc_Word32 AudioDeviceWindowsWave::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord32 minVol(0);
@ -907,7 +888,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MinSpeakerVolume(WebRtc_UWord32& minVolume
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -926,7 +906,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerVolumeStepSize(WebRtc_UWord16& step
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool isAvailable(false);
@ -960,7 +939,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::SetSpeakerMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetSpeakerMute(enable=%u)", enable);
return (_mixerManager.SetSpeakerMute(enable));
}
@ -970,7 +948,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioDeviceWindowsWave::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool muted(0);
@ -989,7 +966,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SpeakerMute(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneMuteIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool isAvailable(false);
@ -1023,7 +999,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneMuteIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::SetMicrophoneMute(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetMicrophoneMute(enable=%u)", enable);
return (_mixerManager.SetMicrophoneMute(enable));
}
@ -1033,7 +1008,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool muted(0);
@ -1052,7 +1026,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneMute(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneBoostIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool isAvailable(false);
@ -1086,7 +1059,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneBoostIsAvailable(bool& available
WebRtc_Word32 AudioDeviceWindowsWave::SetMicrophoneBoost(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetMicrophoneBoost(enable=%u)", enable);
return (_mixerManager.SetMicrophoneBoost(enable));
}
@ -1097,7 +1069,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool onOff(0);
@ -1116,7 +1087,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneBoost(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsWave::StereoRecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
return 0;
}
@ -1127,7 +1097,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StereoRecordingIsAvailable(bool& available
WebRtc_Word32 AudioDeviceWindowsWave::SetStereoRecording(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetStereoRecording(enable=%u)", enable);
if (enable)
_recChannels = 2;
@ -1143,7 +1112,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetStereoRecording(bool enable)
WebRtc_Word32 AudioDeviceWindowsWave::StereoRecording(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_recChannels == 2)
enabled = true;
@ -1159,7 +1127,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StereoRecording(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsWave::StereoPlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = true;
return 0;
}
@ -1189,7 +1156,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StereoPlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::SetStereoPlayout(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetStereoPlayout(enable=%u)", enable);
if (enable)
_playChannels = 2;
@ -1205,7 +1171,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetStereoPlayout(bool enable)
WebRtc_Word32 AudioDeviceWindowsWave::StereoPlayout(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_playChannels == 2)
enabled = true;
@ -1221,7 +1186,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StereoPlayout(bool& enabled) const
WebRtc_Word32 AudioDeviceWindowsWave::SetAGC(bool enable)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetAGC(enable=%d)", enable);
_AGC = enable;
@ -1243,7 +1207,6 @@ bool AudioDeviceWindowsWave::AGC() const
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneVolumeIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
bool isAvailable(false);
@ -1332,7 +1295,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MinMicrophoneVolume(WebRtc_UWord32& minVol
WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord16 delta(0);
@ -1351,7 +1313,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::MicrophoneVolumeStepSize(WebRtc_UWord16& s
WebRtc_Word16 AudioDeviceWindowsWave::PlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (waveOutGetNumDevs());
}
@ -1362,7 +1323,6 @@ WebRtc_Word16 AudioDeviceWindowsWave::PlayoutDevices()
WebRtc_Word32 AudioDeviceWindowsWave::SetPlayoutDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetPlayoutDevice(index=%u)", index);
if (_playIsInitialized)
{
@ -1398,11 +1358,9 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetPlayoutDevice(AudioDeviceModule::Window
if (device == AudioDeviceModule::kDefaultDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetPlayoutDevice(kDefaultDevice)");
}
else if (device == AudioDeviceModule::kDefaultCommunicationDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetPlayoutDevice(kDefaultCommunicationDevice)");
}
_usingOutputDeviceIndex = false;
@ -1418,7 +1376,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetPlayoutDevice(AudioDeviceModule::Window
WebRtc_Word32 AudioDeviceWindowsWave::PlayoutDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::PlayoutDeviceName(index=%u)", index);
WebRtc_UWord16 nDevices(PlayoutDevices());
@ -1521,7 +1478,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::PlayoutDeviceName(WebRtc_UWord16 index, We
WebRtc_Word32 AudioDeviceWindowsWave::RecordingDeviceName(WebRtc_UWord16 index, WebRtc_Word8 name[kAdmMaxDeviceNameSize], WebRtc_Word8 guid[kAdmMaxGuidSize])
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::RecordingDeviceName(index=%u)", index);
WebRtc_UWord16 nDevices(RecordingDevices());
@ -1624,7 +1580,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::RecordingDeviceName(WebRtc_UWord16 index,
WebRtc_Word16 AudioDeviceWindowsWave::RecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (waveInGetNumDevs());
}
@ -1635,7 +1590,6 @@ WebRtc_Word16 AudioDeviceWindowsWave::RecordingDevices()
WebRtc_Word32 AudioDeviceWindowsWave::SetRecordingDevice(WebRtc_UWord16 index)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetRecordingDevice(index=%u)", index);
if (_recIsInitialized)
{
@ -1666,11 +1620,9 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetRecordingDevice(AudioDeviceModule::Wind
{
if (device == AudioDeviceModule::kDefaultDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetRecordingDevice(kDefaultDevice)");
}
else if (device == AudioDeviceModule::kDefaultCommunicationDevice)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetRecordingDevice(kDefaultCommunicationDevice)");
}
if (_recIsInitialized)
@ -1691,7 +1643,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetRecordingDevice(AudioDeviceModule::Wind
WebRtc_Word32 AudioDeviceWindowsWave::PlayoutIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -1715,7 +1666,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::PlayoutIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::RecordingIsAvailable(bool& available)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
available = false;
@ -1739,7 +1689,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::RecordingIsAvailable(bool& available)
WebRtc_Word32 AudioDeviceWindowsWave::InitPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -1936,7 +1885,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::InitPlayout()
WebRtc_Word32 AudioDeviceWindowsWave::InitRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2088,7 +2036,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::InitRecording()
WebRtc_Word32 AudioDeviceWindowsWave::StartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_recIsInitialized)
{
@ -2115,7 +2062,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StartRecording()
if (_recording)
{
// the recording state is set by the audio thread after recording has started
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "recording is now active");
}
else
{
@ -2132,7 +2078,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StartRecording()
WebRtc_Word32 AudioDeviceWindowsWave::StopRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2215,7 +2160,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StopRecording()
bool AudioDeviceWindowsWave::RecordingIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recIsInitialized);
}
@ -2225,7 +2169,6 @@ bool AudioDeviceWindowsWave::RecordingIsInitialized() const
bool AudioDeviceWindowsWave::Recording() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_recording);
}
@ -2235,7 +2178,6 @@ bool AudioDeviceWindowsWave::Recording() const
bool AudioDeviceWindowsWave::PlayoutIsInitialized() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playIsInitialized);
}
@ -2245,7 +2187,6 @@ bool AudioDeviceWindowsWave::PlayoutIsInitialized() const
WebRtc_Word32 AudioDeviceWindowsWave::StartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (!_playIsInitialized)
{
@ -2272,7 +2213,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StartPlayout()
if (_playing)
{
// the playing state is set by the audio thread after playout has started
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "playing is now active");
}
else
{
@ -2289,7 +2229,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::StartPlayout()
WebRtc_Word32 AudioDeviceWindowsWave::StopPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2385,7 +2324,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::RecordingDelay(WebRtc_UWord16& delayMS) co
bool AudioDeviceWindowsWave::Playing() const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
return (_playing);
}
// ----------------------------------------------------------------------------
@ -2394,7 +2332,6 @@ bool AudioDeviceWindowsWave::Playing() const
WebRtc_Word32 AudioDeviceWindowsWave::SetPlayoutBuffer(const AudioDeviceModule::BufferType type, WebRtc_UWord16 sizeMS)
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "AudioDeviceWindowsWave::SetPlayoutBuffer(type=%u, sizeMS=%u)", type, sizeMS);
CriticalSectionScoped lock(_critSect);
_playBufType = type;
if (type == AudioDeviceModule::kFixedBufferSize)
@ -2410,7 +2347,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::SetPlayoutBuffer(const AudioDeviceModule::
WebRtc_Word32 AudioDeviceWindowsWave::PlayoutBuffer(AudioDeviceModule::BufferType& type, WebRtc_UWord16& sizeMS) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
type = _playBufType;
if (type == AudioDeviceModule::kFixedBufferSize)
@ -2431,7 +2367,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::PlayoutBuffer(AudioDeviceModule::BufferTyp
WebRtc_Word32 AudioDeviceWindowsWave::CPULoad(WebRtc_UWord16& load) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
load = static_cast<WebRtc_UWord16>(100*_avgCPULoad);
@ -2548,7 +2483,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::OutputSanityCheckAfterUnlockedPeriod() con
WebRtc_Word32 AudioDeviceWindowsWave::EnumeratePlayoutDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord16 nDevices(PlayoutDevices());
WEBRTC_TRACE(kTraceInfo, kTraceAudioDevice, _id, "===============================================================");
@ -2601,7 +2535,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::EnumeratePlayoutDevices()
WebRtc_Word32 AudioDeviceWindowsWave::EnumerateRecordingDevices()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
WebRtc_UWord16 nDevices(RecordingDevices());
WEBRTC_TRACE(kTraceInfo, kTraceAudioDevice, _id, "===============================================================");
@ -2727,7 +2660,6 @@ void AudioDeviceWindowsWave::TraceWaveOutError(MMRESULT error) const
WebRtc_Word32 AudioDeviceWindowsWave::PrepareStartPlayout()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);
@ -2765,7 +2697,6 @@ WebRtc_Word32 AudioDeviceWindowsWave::PrepareStartPlayout()
WebRtc_Word32 AudioDeviceWindowsWave::PrepareStartRecording()
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
CriticalSectionScoped lock(_critSect);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
* Copyright (c) 2012 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
@ -1063,7 +1063,6 @@ WebRtc_Word32 AudioMixerManager::SetSpeakerVolume(WebRtc_UWord32 volume)
WebRtc_Word32 AudioMixerManager::SpeakerVolume(WebRtc_UWord32& volume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -1096,7 +1095,6 @@ WebRtc_Word32 AudioMixerManager::SpeakerVolume(WebRtc_UWord32& volume) const
WebRtc_Word32 AudioMixerManager::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -1126,7 +1124,6 @@ WebRtc_Word32 AudioMixerManager::MaxSpeakerVolume(WebRtc_UWord32& maxVolume) con
WebRtc_Word32 AudioMixerManager::MinSpeakerVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -1156,7 +1153,6 @@ WebRtc_Word32 AudioMixerManager::MinSpeakerVolume(WebRtc_UWord32& minVolume) con
WebRtc_Word32 AudioMixerManager::SpeakerVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -1260,7 +1256,6 @@ WebRtc_Word32 AudioMixerManager::SetSpeakerMute(bool enable)
WebRtc_Word32 AudioMixerManager::SpeakerMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_outputMixerHandle == NULL)
{
@ -1356,7 +1351,6 @@ WebRtc_Word32 AudioMixerManager::SetMicrophoneMute(bool enable)
WebRtc_Word32 AudioMixerManager::MicrophoneMute(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{
@ -1450,7 +1444,6 @@ WebRtc_Word32 AudioMixerManager::SetMicrophoneBoost(bool enable)
WebRtc_Word32 AudioMixerManager::MicrophoneBoost(bool& enabled) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{
@ -1594,7 +1587,6 @@ WebRtc_Word32 AudioMixerManager::MaxMicrophoneVolume(WebRtc_UWord32& maxVolume)
WebRtc_Word32 AudioMixerManager::MinMicrophoneVolume(WebRtc_UWord32& minVolume) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{
@ -1624,7 +1616,6 @@ WebRtc_Word32 AudioMixerManager::MinMicrophoneVolume(WebRtc_UWord32& minVolume)
WebRtc_Word32 AudioMixerManager::MicrophoneVolumeStepSize(WebRtc_UWord16& stepSize) const
{
WEBRTC_TRACE(kTraceModuleCall, kTraceAudioDevice, _id, "%s", __FUNCTION__);
if (_inputMixerHandle == NULL)
{