|
@@ -257,6 +257,24 @@ export default class ConnectionQuality {
|
257
|
257
|
// TODO: take into account packet loss for received streams
|
258
|
258
|
if (this._localStats.packetLoss) {
|
259
|
259
|
packetLoss = this._localStats.packetLoss.upload;
|
|
260
|
+
|
|
261
|
+ // Ugly Hack Alert (UHA):
|
|
262
|
+ // The packet loss for the upload direction is calculated based on
|
|
263
|
+ // incoming RTCP Receiver Reports. Since we don't have RTCP
|
|
264
|
+ // termination for audio, these reports come from the actual
|
|
265
|
+ // receivers in the conference and therefore the reported packet
|
|
266
|
+ // loss includes loss from the bridge to the receiver.
|
|
267
|
+ // When we are sending video this effect is small, because the
|
|
268
|
+ // number of video packets is much larger than the number of audio
|
|
269
|
+ // packets (and our calculation is based on the total number of
|
|
270
|
+ // received and lost packets).
|
|
271
|
+ // When video is muted, however, the effect might be significant,
|
|
272
|
+ // but we don't know what it is. We do know that it is positive, so
|
|
273
|
+ // as a temporary solution, until RTCP termination is implemented
|
|
274
|
+ // for the audio streams, we relax the packet loss checks here.
|
|
275
|
+ if (isMuted) {
|
|
276
|
+ packetLoss *= 0.5;
|
|
277
|
+ }
|
260
|
278
|
}
|
261
|
279
|
|
262
|
280
|
if (isMuted || !resolution || videoType === VideoType.DESKTOP
|