Don't add the x-goog-conference flag if there are no simulcast senders

This commit is contained in:
George Politis 2014-11-10 10:02:04 +01:00
parent aa5c2c11ad
commit 41fd416338
1 changed files with 20 additions and 17 deletions

View File

@ -732,6 +732,7 @@ NativeSimulcastSender.prototype.transformLocalDescription = function (desc) {
*/
SimulcastReceiver.prototype.transformRemoteDescription = function (desc) {
if (desc && desc.sdp) {
var sb = desc.sdp.split('\r\n');
this._updateRemoteMaps(sb);
@ -740,10 +741,11 @@ SimulcastReceiver.prototype.transformRemoteDescription = function (desc) {
// NOTE(gp) this needs to be called after updateRemoteMaps because we need the simulcast group in the _updateRemoteMaps() method.
this.simulcastUtils._removeSimulcastGroup(sb);
// We don't need the goog conference flag if we're not doing native
// simulcast, but at the receiver, we have no idea if the sender is
// doing native or not-native simulcast.
if (desc.sdp.indexOf('a=ssrc-group:SIM') !== -1) {
// We don't need the goog conference flag if we're not doing
// simulcast.
this._ensureGoogConference(sb);
}
desc = new RTCSessionDescription({
type: desc.type,
@ -751,6 +753,7 @@ SimulcastReceiver.prototype.transformRemoteDescription = function (desc) {
});
this.logger.fine(['Transformed remote description', desc.sdp].join(' '));
}
return desc;
};