aboutsummaryrefslogtreecommitdiff
path: root/call/call.cc
diff options
context:
space:
mode:
authorTommi <tommi@webrtc.org>2021-06-16 16:31:18 +0200
committerWebRTC LUCI CQ <webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com>2021-06-16 19:34:18 +0000
commit55107c8507596b98d569f9304b15b6b5847936a4 (patch)
tree8ef42a02af3e23c133d221b465fb088040fe7c40 /call/call.cc
parent25029c4135ebd5ea1f07cbcca33764674b4ce0a6 (diff)
downloadwebrtc-55107c8507596b98d569f9304b15b6b5847936a4.tar.gz
Update the sync_group id without recreating audio receive streams.
Bug: webrtc:11993 Change-Id: I7aaff6d6f89332e60967fba741252b630fd941cf Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/222043 Commit-Queue: Tommi <tommi@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/master@{#34308}
Diffstat (limited to 'call/call.cc')
-rw-r--r--call/call.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/call/call.cc b/call/call.cc
index b9ce0eb8a7..f4a7d7cc9e 100644
--- a/call/call.cc
+++ b/call/call.cc
@@ -272,6 +272,9 @@ class Call final : public webrtc::Call,
void OnLocalSsrcUpdated(webrtc::AudioReceiveStream& stream,
uint32_t local_ssrc) override;
+ void OnUpdateSyncGroup(webrtc::AudioReceiveStream& stream,
+ const std::string& sync_group) override;
+
void OnSentPacket(const rtc::SentPacket& sent_packet) override;
// Implements TargetTransferRateObserver,
@@ -1371,6 +1374,15 @@ void Call::OnLocalSsrcUpdated(webrtc::AudioReceiveStream& stream,
: nullptr);
}
+void Call::OnUpdateSyncGroup(webrtc::AudioReceiveStream& stream,
+ const std::string& sync_group) {
+ RTC_DCHECK_RUN_ON(worker_thread_);
+ webrtc::internal::AudioReceiveStream& receive_stream =
+ static_cast<webrtc::internal::AudioReceiveStream&>(stream);
+ receive_stream.SetSyncGroup(sync_group);
+ ConfigureSync(sync_group);
+}
+
void Call::OnSentPacket(const rtc::SentPacket& sent_packet) {
// In production and with most tests, this method will be called on the
// network thread. However some test classes such as DirectTransport don't