aboutsummaryrefslogtreecommitdiff
path: root/audio
diff options
context:
space:
mode:
authorTomas Gunnarsson <tommi@webrtc.org>2020-06-03 08:54:39 +0200
committerCommit Bot <commit-bot@chromium.org>2020-06-03 09:41:34 +0000
commitfae05624ec66e67618eb53183ea10d546f89560d (patch)
treec3ea3c168615c182816d4a17c279490f6e029539 /audio
parent878808892da4915dc646a0a193f9ee5ba3bd6764 (diff)
downloadwebrtc-fae05624ec66e67618eb53183ea10d546f89560d.tar.gz
Deprecate the static RtpRtcp::Create() method.
The method is being used externally to create instances of the deprecated internal implementation. Instead, I'm moving how we instantiate the internal implementation into the implementation itself and move towards keeping the interface separate from a single implementation. Change-Id: I743aa86dc4c812b545699c546c253c104719260e Bug: webrtc:11581 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/176404 Commit-Queue: Tommi <tommi@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/master@{#31420}
Diffstat (limited to 'audio')
-rw-r--r--audio/channel_receive.cc4
-rw-r--r--audio/channel_send.cc3
-rw-r--r--audio/voip/audio_channel.cc3
-rw-r--r--audio/voip/test/BUILD.gn3
-rw-r--r--audio/voip/test/audio_egress_unittest.cc3
-rw-r--r--audio/voip/test/audio_ingress_unittest.cc3
6 files changed, 13 insertions, 6 deletions
diff --git a/audio/channel_receive.cc b/audio/channel_receive.cc
index 66b4bb11f5..c4278444ab 100644
--- a/audio/channel_receive.cc
+++ b/audio/channel_receive.cc
@@ -33,11 +33,11 @@
#include "modules/pacing/packet_router.h"
#include "modules/rtp_rtcp/include/receive_statistics.h"
#include "modules/rtp_rtcp/include/remote_ntp_time_estimator.h"
-#include "modules/rtp_rtcp/include/rtp_rtcp.h"
#include "modules/rtp_rtcp/source/absolute_capture_time_receiver.h"
#include "modules/rtp_rtcp/source/rtp_header_extensions.h"
#include "modules/rtp_rtcp/source/rtp_packet_received.h"
#include "modules/rtp_rtcp/source/rtp_rtcp_config.h"
+#include "modules/rtp_rtcp/source/rtp_rtcp_impl2.h"
#include "modules/utility/include/process_thread.h"
#include "rtc_base/checks.h"
#include "rtc_base/critical_section.h"
@@ -507,7 +507,7 @@ ChannelReceive::ChannelReceive(
if (frame_transformer)
InitFrameTransformerDelegate(std::move(frame_transformer));
- _rtpRtcpModule = RtpRtcp::Create(configuration);
+ _rtpRtcpModule = ModuleRtpRtcpImpl2::Create(configuration);
_rtpRtcpModule->SetSendingMediaStatus(false);
_rtpRtcpModule->SetRemoteSSRC(remote_ssrc_);
diff --git a/audio/channel_send.cc b/audio/channel_send.cc
index 3387f271ba..1c18a8b9b7 100644
--- a/audio/channel_send.cc
+++ b/audio/channel_send.cc
@@ -29,6 +29,7 @@
#include "modules/audio_coding/include/audio_coding_module.h"
#include "modules/audio_processing/rms_level.h"
#include "modules/pacing/packet_router.h"
+#include "modules/rtp_rtcp/source/rtp_rtcp_impl2.h"
#include "modules/utility/include/process_thread.h"
#include "rtc_base/checks.h"
#include "rtc_base/event.h"
@@ -530,7 +531,7 @@ ChannelSend::ChannelSend(
configuration.local_media_ssrc = ssrc;
- _rtpRtcpModule = RtpRtcp::Create(configuration);
+ _rtpRtcpModule = ModuleRtpRtcpImpl2::Create(configuration);
_rtpRtcpModule->SetSendingMediaStatus(false);
rtp_sender_audio_ = std::make_unique<RTPSenderAudio>(
diff --git a/audio/voip/audio_channel.cc b/audio/voip/audio_channel.cc
index b9ce7accd1..455c43c48b 100644
--- a/audio/voip/audio_channel.cc
+++ b/audio/voip/audio_channel.cc
@@ -16,6 +16,7 @@
#include "api/audio_codecs/audio_format.h"
#include "api/task_queue/task_queue_factory.h"
#include "modules/rtp_rtcp/include/receive_statistics.h"
+#include "modules/rtp_rtcp/source/rtp_rtcp_impl2.h"
#include "rtc_base/critical_section.h"
#include "rtc_base/location.h"
#include "rtc_base/logging.h"
@@ -51,7 +52,7 @@ AudioChannel::AudioChannel(
rtp_config.outgoing_transport = transport;
rtp_config.local_media_ssrc = local_ssrc;
- rtp_rtcp_ = RtpRtcp::Create(rtp_config);
+ rtp_rtcp_ = ModuleRtpRtcpImpl2::Create(rtp_config);
rtp_rtcp_->SetSendingMediaStatus(false);
rtp_rtcp_->SetRTCPStatus(RtcpMode::kCompound);
diff --git a/audio/voip/test/BUILD.gn b/audio/voip/test/BUILD.gn
index 39f100a3aa..d698b3321d 100644
--- a/audio/voip/test/BUILD.gn
+++ b/audio/voip/test/BUILD.gn
@@ -36,6 +36,7 @@ if (rtc_include_tests) {
"../../../api/task_queue:default_task_queue_factory",
"../../../modules/audio_mixer:audio_mixer_impl",
"../../../modules/audio_mixer:audio_mixer_test_utils",
+ "../../../modules/rtp_rtcp:rtp_rtcp",
"../../../modules/rtp_rtcp:rtp_rtcp_format",
"../../../modules/utility",
"../../../rtc_base:logging",
@@ -56,6 +57,7 @@ if (rtc_include_tests) {
"../../../api/audio_codecs:builtin_audio_encoder_factory",
"../../../api/task_queue:default_task_queue_factory",
"../../../modules/audio_mixer:audio_mixer_test_utils",
+ "../../../modules/rtp_rtcp:rtp_rtcp",
"../../../rtc_base:logging",
"../../../rtc_base:rtc_event",
"../../../test:mock_transport",
@@ -72,6 +74,7 @@ if (rtc_include_tests) {
"../../../api/audio_codecs:builtin_audio_encoder_factory",
"../../../api/task_queue:default_task_queue_factory",
"../../../modules/audio_mixer:audio_mixer_test_utils",
+ "../../../modules/rtp_rtcp:rtp_rtcp",
"../../../modules/rtp_rtcp:rtp_rtcp_format",
"../../../rtc_base:logging",
"../../../rtc_base:rtc_event",
diff --git a/audio/voip/test/audio_egress_unittest.cc b/audio/voip/test/audio_egress_unittest.cc
index 3391265880..ebb1772b30 100644
--- a/audio/voip/test/audio_egress_unittest.cc
+++ b/audio/voip/test/audio_egress_unittest.cc
@@ -14,6 +14,7 @@
#include "api/task_queue/default_task_queue_factory.h"
#include "modules/audio_mixer/sine_wave_generator.h"
#include "modules/rtp_rtcp/source/rtp_packet_received.h"
+#include "modules/rtp_rtcp/source/rtp_rtcp_impl2.h"
#include "rtc_base/event.h"
#include "rtc_base/logging.h"
#include "test/gmock.h"
@@ -36,7 +37,7 @@ std::unique_ptr<RtpRtcp> CreateRtpStack(Clock* clock,
rtp_config.rtcp_report_interval_ms = 5000;
rtp_config.outgoing_transport = transport;
rtp_config.local_media_ssrc = remote_ssrc;
- auto rtp_rtcp = RtpRtcp::Create(rtp_config);
+ auto rtp_rtcp = ModuleRtpRtcpImpl2::Create(rtp_config);
rtp_rtcp->SetSendingMediaStatus(false);
rtp_rtcp->SetRTCPStatus(RtcpMode::kCompound);
return rtp_rtcp;
diff --git a/audio/voip/test/audio_ingress_unittest.cc b/audio/voip/test/audio_ingress_unittest.cc
index bedb82e211..91d114c52d 100644
--- a/audio/voip/test/audio_ingress_unittest.cc
+++ b/audio/voip/test/audio_ingress_unittest.cc
@@ -15,6 +15,7 @@
#include "api/task_queue/default_task_queue_factory.h"
#include "audio/voip/audio_egress.h"
#include "modules/audio_mixer/sine_wave_generator.h"
+#include "modules/rtp_rtcp/source/rtp_rtcp_impl2.h"
#include "rtc_base/event.h"
#include "rtc_base/logging.h"
#include "test/gmock.h"
@@ -45,7 +46,7 @@ class AudioIngressTest : public ::testing::Test {
rtp_config.rtcp_report_interval_ms = 5000;
rtp_config.outgoing_transport = &transport_;
rtp_config.local_media_ssrc = 0xdeadc0de;
- rtp_rtcp_ = RtpRtcp::Create(rtp_config);
+ rtp_rtcp_ = ModuleRtpRtcpImpl2::Create(rtp_config);
rtp_rtcp_->SetSendingMediaStatus(false);
rtp_rtcp_->SetRTCPStatus(RtcpMode::kCompound);