(Auto)update libjingle 74235596-> 74297316

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6997 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
buildbot@webrtc.org 2014-08-28 10:52:44 +00:00
parent 59a1b1b928
commit 1f8a23757a
2 changed files with 45 additions and 32 deletions

View File

@ -806,30 +806,6 @@ bool WebRtcVoiceEngine::ApplyOptions(const AudioOptions& options_in) {
}
}
bool experimental_ns;
if (options.experimental_ns.Get(&experimental_ns)) {
webrtc::AudioProcessing* audioproc =
voe_wrapper_->base()->audio_processing();
#ifdef USE_WEBRTC_DEV_BRANCH
webrtc::Config config;
config.Set<webrtc::ExperimentalNs>(new webrtc::ExperimentalNs(
experimental_ns));
audioproc->SetExtraOptions(config);
#else
// We check audioproc for the benefit of tests, since FakeWebRtcVoiceEngine
// returns NULL on audio_processing().
if (audioproc) {
if (audioproc->EnableExperimentalNs(experimental_ns) == -1) {
LOG_RTCERR1(EnableExperimentalNs, experimental_ns);
return false;
}
} else {
LOG(LS_VERBOSE) << "Experimental noise suppression set to "
<< experimental_ns;
}
#endif
}
bool highpass_filter;
if (options.highpass_filter.Get(&highpass_filter)) {
LOG(LS_INFO) << "High pass filter enabled? " << highpass_filter;
@ -875,20 +851,50 @@ bool WebRtcVoiceEngine::ApplyOptions(const AudioOptions& options_in) {
StopAecDump();
}
webrtc::Config config;
experimental_aec_.SetFrom(options.experimental_aec);
bool experimental_aec;
if (options.experimental_aec.Get(&experimental_aec)) {
LOG(LS_INFO) << "Experimental aec is " << experimental_aec;
webrtc::AudioProcessing* audioproc =
voe_wrapper_->base()->audio_processing();
if (experimental_aec_.Get(&experimental_aec)) {
LOG(LS_INFO) << "Experimental aec is enabled? " << experimental_aec;
config.Set<webrtc::DelayCorrection>(
new webrtc::DelayCorrection(experimental_aec));
}
#ifdef USE_WEBRTC_DEV_BRANCH
experimental_ns_.SetFrom(options.experimental_ns);
bool experimental_ns;
if (experimental_ns_.Get(&experimental_ns)) {
LOG(LS_INFO) << "Experimental ns is enabled? " << experimental_ns;
config.Set<webrtc::ExperimentalNs>(
new webrtc::ExperimentalNs(experimental_ns));
}
#endif
// We check audioproc for the benefit of tests, since FakeWebRtcVoiceEngine
// returns NULL on audio_processing().
webrtc::AudioProcessing* audioproc = voe_wrapper_->base()->audio_processing();
if (audioproc) {
audioproc->SetExtraOptions(config);
}
#ifndef USE_WEBRTC_DEV_BRANCH
bool experimental_ns;
if (options.experimental_ns.Get(&experimental_ns)) {
LOG(LS_INFO) << "Experimental ns is enabled? " << experimental_ns;
// We check audioproc for the benefit of tests, since FakeWebRtcVoiceEngine
// returns NULL on audio_processing().
if (audioproc) {
webrtc::Config config;
config.Set<webrtc::DelayCorrection>(
new webrtc::DelayCorrection(experimental_aec));
audioproc->SetExtraOptions(config);
if (audioproc->EnableExperimentalNs(experimental_ns) == -1) {
LOG_RTCERR1(EnableExperimentalNs, experimental_ns);
return false;
}
} else {
LOG(LS_VERBOSE) << "Experimental noise suppression set to "
<< experimental_ns;
}
}
#endif
uint32 recording_sample_rate;
if (options.recording_sample_rate.Get(&recording_sample_rate)) {

View File

@ -284,6 +284,13 @@ class WebRtcVoiceEngine
uint32 rx_processor_ssrc_;
rtc::CriticalSection signal_media_critical_;
// Cache received experimental_aec and experimental_ns values, and apply them
// in case they are missing in the audio options. We need to do this because
// SetExtraOptions() will revert to defaults for options which are not
// provided.
Settable<bool> experimental_aec_;
Settable<bool> experimental_ns_;
};
// WebRtcMediaChannel is a class that implements the common WebRtc channel