|
@@ -221,11 +221,17 @@ export class ReceiveVideoController {
|
221
|
221
|
this._selectedEndpoints = ids;
|
222
|
222
|
|
223
|
223
|
if (this._receiverVideoConstraints) {
|
|
224
|
+ // Filter out the local endpointId from the list of selected endpoints.
|
224
|
225
|
const remoteEndpointIds = ids.filter(id => id !== this._conference.myUserId());
|
|
226
|
+ const oldConstraints = this._receiverVideoConstraints.constraints;
|
225
|
227
|
|
226
|
|
- // Filter out the local endpointId from the list of selected endpoints.
|
227
|
228
|
remoteEndpointIds.length && this._receiverVideoConstraints.updateSelectedEndpoints(remoteEndpointIds);
|
228
|
|
- this._rtc.setNewReceiverVideoConstraints(this._receiverVideoConstraints.constraints);
|
|
229
|
+ const newConstraints = this._receiverVideoConstraints.constraints;
|
|
230
|
+
|
|
231
|
+ // Send bridge message only when the constraints change.
|
|
232
|
+ if (!isEqual(newConstraints, oldConstraints)) {
|
|
233
|
+ this._rtc.setNewReceiverVideoConstraints(newConstraints);
|
|
234
|
+ }
|
229
|
235
|
|
230
|
236
|
return;
|
231
|
237
|
}
|