Add support for setting a custom NetEqFactory in PeerConnection level tests.
This allows running Peerconnection level tests with a custom NetEqFactory. Bug: webrtc:11005 Change-Id: If3063cf61a6274a137e4ab74f9ec2665425f21ae Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/161307 Reviewed-by: Artem Titov <titovartem@webrtc.org> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org> Commit-Queue: Ivo Creusen <ivoc@webrtc.org> Cr-Commit-Position: refs/heads/master@{#30028}
This commit is contained in:
parent
ee1e015655
commit
1518fd34d8
@ -299,6 +299,9 @@ class PeerConnectionE2EQualityTestFixture {
|
|||||||
// Set the audio stream for the call from this peer. If this method won't
|
// Set the audio stream for the call from this peer. If this method won't
|
||||||
// be invoked, this peer will send no audio.
|
// be invoked, this peer will send no audio.
|
||||||
virtual PeerConfigurer* SetAudioConfig(AudioConfig config) = 0;
|
virtual PeerConfigurer* SetAudioConfig(AudioConfig config) = 0;
|
||||||
|
// Set a custom NetEqFactory to be used in the call.
|
||||||
|
virtual PeerConfigurer* SetNetEqFactory(
|
||||||
|
std::unique_ptr<NetEqFactory> neteq_factory) = 0;
|
||||||
// If is set, an RTCEventLog will be saved in that location and it will be
|
// If is set, an RTCEventLog will be saved in that location and it will be
|
||||||
// available for further analysis.
|
// available for further analysis.
|
||||||
virtual PeerConfigurer* SetRtcEventLogPath(std::string path) = 0;
|
virtual PeerConfigurer* SetRtcEventLogPath(std::string path) = 0;
|
||||||
|
|||||||
@ -136,6 +136,11 @@ class PeerConfigurerImpl final
|
|||||||
params_->audio_config = std::move(config);
|
params_->audio_config = std::move(config);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
PeerConfigurer* SetNetEqFactory(
|
||||||
|
std::unique_ptr<NetEqFactory> neteq_factory) override {
|
||||||
|
components_->pcf_dependencies->neteq_factory = std::move(neteq_factory);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
PeerConfigurer* SetRtcEventLogPath(std::string path) override {
|
PeerConfigurer* SetRtcEventLogPath(std::string path) override {
|
||||||
params_->rtc_event_log_path = std::move(path);
|
params_->rtc_event_log_path = std::move(path);
|
||||||
return this;
|
return this;
|
||||||
|
|||||||
@ -48,6 +48,7 @@ struct PeerConnectionFactoryComponents {
|
|||||||
std::unique_ptr<FecControllerFactoryInterface> fec_controller_factory;
|
std::unique_ptr<FecControllerFactoryInterface> fec_controller_factory;
|
||||||
std::unique_ptr<NetworkControllerFactoryInterface> network_controller_factory;
|
std::unique_ptr<NetworkControllerFactoryInterface> network_controller_factory;
|
||||||
std::unique_ptr<MediaTransportFactory> media_transport_factory;
|
std::unique_ptr<MediaTransportFactory> media_transport_factory;
|
||||||
|
std::unique_ptr<NetEqFactory> neteq_factory;
|
||||||
|
|
||||||
// Will be passed to MediaEngineInterface, that will be used in
|
// Will be passed to MediaEngineInterface, that will be used in
|
||||||
// PeerConnectionFactory.
|
// PeerConnectionFactory.
|
||||||
|
|||||||
@ -162,6 +162,9 @@ class TestPeerComponents {
|
|||||||
pcf_deps.media_transport_factory =
|
pcf_deps.media_transport_factory =
|
||||||
std::move(pcf_dependencies->media_transport_factory);
|
std::move(pcf_dependencies->media_transport_factory);
|
||||||
}
|
}
|
||||||
|
if (pcf_dependencies->neteq_factory != nullptr) {
|
||||||
|
pcf_deps.neteq_factory = std::move(pcf_dependencies->neteq_factory);
|
||||||
|
}
|
||||||
|
|
||||||
return pcf_deps;
|
return pcf_deps;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user