Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(319)

Unified Diff: webrtc/media/engine/fakewebrtcvoiceengine.h

Issue 2307533004: Moving/renaming webrtc/common.h. (Closed)
Patch Set: gyp fix Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/media/engine/fakewebrtcvoiceengine.h
diff --git a/webrtc/media/engine/fakewebrtcvoiceengine.h b/webrtc/media/engine/fakewebrtcvoiceengine.h
index 9b5440c17b1f5b421626987050478fd893568c85..32fd9312c0b69463515410473c3ae117e7f580f6 100644
--- a/webrtc/media/engine/fakewebrtcvoiceengine.h
+++ b/webrtc/media/engine/fakewebrtcvoiceengine.h
@@ -190,18 +190,15 @@ class FakeWebRtcVoiceEngine
void set_fail_create_channel(bool fail_create_channel) {
fail_create_channel_ = fail_create_channel;
}
- int AddChannel(const webrtc::Config& config) {
+ int AddChannel(const webrtc::AudioCodingModule::Config& acm_config) {
if (fail_create_channel_) {
return -1;
}
Channel* ch = new Channel();
auto db = webrtc::acm2::RentACodec::Database();
ch->recv_codecs.assign(db.begin(), db.end());
- if (config.Get<webrtc::NetEqCapacityConfig>().enabled) {
- ch->neteq_capacity = config.Get<webrtc::NetEqCapacityConfig>().capacity;
- }
- ch->neteq_fast_accelerate =
- config.Get<webrtc::NetEqFastAccelerate>().enabled;
+ ch->neteq_capacity = acm_config.neteq_config.max_packets_in_buffer;
+ ch->neteq_fast_accelerate = acm_config.neteq_config.enable_fast_accelerate;
channels_[++last_channel_] = ch;
return last_channel_;
}
@@ -237,11 +234,11 @@ class FakeWebRtcVoiceEngine
return nullptr;
}
WEBRTC_FUNC(CreateChannel, ()) {
- webrtc::Config empty_config;
- return AddChannel(empty_config);
+ return AddChannel(webrtc::AudioCodingModule::Config());
}
- WEBRTC_FUNC(CreateChannel, (const webrtc::Config& config)) {
- return AddChannel(config);
+ WEBRTC_FUNC(CreateChannel,
+ (const webrtc::AudioCodingModule::Config& acm_config)) {
+ return AddChannel(acm_config);
}
WEBRTC_FUNC(DeleteChannel, (int channel)) {
WEBRTC_CHECK_CHANNEL(channel);

Powered by Google App Engine
This is Rietveld 408576698