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

Unified Diff: webrtc/pc/mediasession.cc

Issue 2810733003: Fix SDP stream ID mismatch issue when a track's stream changes. (Closed)
Patch Set: Created 3 years, 8 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
« no previous file with comments | « webrtc/media/base/streamparams.h ('k') | webrtc/pc/peerconnection_integrationtest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/pc/mediasession.cc
diff --git a/webrtc/pc/mediasession.cc b/webrtc/pc/mediasession.cc
index dbd32566d523d3d67d8ca3be8fee17e7190fcf9f..69b10452a775a8cccab00b38dafb5e39f4cfa218 100644
--- a/webrtc/pc/mediasession.cc
+++ b/webrtc/pc/mediasession.cc
@@ -448,8 +448,7 @@ static bool AddStreamParams(MediaType media_type,
if (stream_it->type != media_type)
continue; // Wrong media type.
- const StreamParams* param =
- GetStreamByIds(*current_streams, "", stream_it->id);
+ StreamParams* param = GetStreamByIds(*current_streams, "", stream_it->id);
pthatcher1 2017/04/13 21:31:21 Instead of making this non-const and adding all th
Taylor Brandstetter 2017/04/14 15:52:08 Just because this way is more convenient/efficient
// groupid is empty for StreamParams generated using
// MediaSessionDescriptionFactory.
if (!param) {
@@ -500,6 +499,10 @@ static bool AddStreamParams(MediaType media_type,
// This is necessary so that we can use the CNAME for other media types.
current_streams->push_back(stream_param);
} else {
+ // Use existing generated SSRCs/groups, but update the sync_label and
+ // cname if necessary.
pthatcher1 2017/04/13 21:31:22 Can you explain why this is necessary in the comme
Taylor Brandstetter 2017/04/14 15:52:08 Done. And there is no stream_it->cname.
+ param->cname = options.rtcp_cname;
+ param->sync_label = stream_it->sync_label;
content_description->AddStream(*param);
}
}
« no previous file with comments | « webrtc/media/base/streamparams.h ('k') | webrtc/pc/peerconnection_integrationtest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698