@dtelecom/livekit-client 1.12.20 → 1.12.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14198,7 +14198,7 @@ function getMatch(exp, ua) {
14198
14198
  return match && match.length >= id && match[id] || '';
14199
14199
  }
14200
14200
 
14201
- var version$1 = "1.12.20";
14201
+ var version$1 = "1.12.21";
14202
14202
 
14203
14203
  const version = version$1;
14204
14204
  const protocolVersion = 9;
@@ -22417,7 +22417,7 @@ class LocalParticipant extends Participant {
22417
22417
  });
22418
22418
  }
22419
22419
  publish(track, opts, options, isStereo) {
22420
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
22420
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
22421
22421
  return __awaiter(this, void 0, void 0, function* () {
22422
22422
  const existingTrackOfSource = Array.from(this.tracks.values()).find(publishedTrack => track instanceof LocalTrack && publishedTrack.source === track.source);
22423
22423
  if (existingTrackOfSource && track.source !== Track.Source.Unknown) {
@@ -22465,8 +22465,8 @@ class LocalParticipant extends Participant {
22465
22465
  source: Track.sourceToProto(track.source),
22466
22466
  disableDtx: !((_a = opts.dtx) !== null && _a !== void 0 ? _a : true),
22467
22467
  encryption: this.encryptionType,
22468
- stereo: isStereo
22469
- // disableRed: !(opts.red ?? true),
22468
+ stereo: isStereo,
22469
+ disableRed: !((_b = opts.red) !== null && _b !== void 0 ? _b : true)
22470
22470
  });
22471
22471
  // compute encodings and layers for video
22472
22472
  let encodings;
@@ -22481,7 +22481,7 @@ class LocalParticipant extends Participant {
22481
22481
  } catch (e) {
22482
22482
  // use defaults, it's quite painful for congestion control without simulcast
22483
22483
  // so using default dims according to publish settings
22484
- const defaultRes = (_c = (_b = this.roomOptions.videoCaptureDefaults) === null || _b === void 0 ? void 0 : _b.resolution) !== null && _c !== void 0 ? _c : VideoPresets.h720.resolution;
22484
+ const defaultRes = (_d = (_c = this.roomOptions.videoCaptureDefaults) === null || _c === void 0 ? void 0 : _c.resolution) !== null && _d !== void 0 ? _d : VideoPresets.h720.resolution;
22485
22485
  dims = {
22486
22486
  width: defaultRes.width,
22487
22487
  height: defaultRes.height
@@ -22496,7 +22496,7 @@ class LocalParticipant extends Participant {
22496
22496
  if (track instanceof LocalVideoTrack) {
22497
22497
  if (isSVCCodec(opts.videoCodec)) {
22498
22498
  // set scalabilityMode to 'L3T3_KEY' by default
22499
- opts.scalabilityMode = (_d = opts.scalabilityMode) !== null && _d !== void 0 ? _d : 'L3T3_KEY';
22499
+ opts.scalabilityMode = (_e = opts.scalabilityMode) !== null && _e !== void 0 ? _e : 'L3T3_KEY';
22500
22500
  }
22501
22501
  // set up backup
22502
22502
  if (opts.videoCodec && opts.backupCodec && opts.videoCodec !== opts.backupCodec.codec) {
@@ -22518,7 +22518,7 @@ class LocalParticipant extends Participant {
22518
22518
  req.simulcastCodecs = [{
22519
22519
  codec: opts.videoCodec,
22520
22520
  cid: track.mediaStreamTrack.id,
22521
- enableSimulcastLayers: (_e = opts.simulcast) !== null && _e !== void 0 ? _e : false
22521
+ enableSimulcastLayers: (_f = opts.simulcast) !== null && _f !== void 0 ? _f : false
22522
22522
  }];
22523
22523
  }
22524
22524
  }
@@ -22526,9 +22526,9 @@ class LocalParticipant extends Participant {
22526
22526
  req.layers = videoLayersFromEncodings(req.width, req.height, encodings, isSVCCodec(opts.videoCodec));
22527
22527
  } else if (track.kind === Track.Kind.Audio) {
22528
22528
  encodings = [{
22529
- maxBitrate: (_g = (_f = opts.audioPreset) === null || _f === void 0 ? void 0 : _f.maxBitrate) !== null && _g !== void 0 ? _g : opts.audioBitrate,
22530
- priority: (_j = (_h = opts.audioPreset) === null || _h === void 0 ? void 0 : _h.priority) !== null && _j !== void 0 ? _j : 'high',
22531
- networkPriority: (_l = (_k = opts.audioPreset) === null || _k === void 0 ? void 0 : _k.priority) !== null && _l !== void 0 ? _l : 'high'
22529
+ maxBitrate: (_h = (_g = opts.audioPreset) === null || _g === void 0 ? void 0 : _g.maxBitrate) !== null && _h !== void 0 ? _h : opts.audioBitrate,
22530
+ priority: (_k = (_j = opts.audioPreset) === null || _j === void 0 ? void 0 : _j.priority) !== null && _k !== void 0 ? _k : 'high',
22531
+ networkPriority: (_m = (_l = opts.audioPreset) === null || _l === void 0 ? void 0 : _l.priority) !== null && _m !== void 0 ? _m : 'high'
22532
22532
  }];
22533
22533
  }
22534
22534
  if (!this.engine || this.engine.isClosed) {
@@ -22590,10 +22590,10 @@ class LocalParticipant extends Participant {
22590
22590
  this.engine.publisher.setTrackCodecBitrate({
22591
22591
  transceiver: trackTransceiver,
22592
22592
  codec: 'opus',
22593
- maxbr: ((_m = encodings[0]) === null || _m === void 0 ? void 0 : _m.maxBitrate) ? encodings[0].maxBitrate / 1000 : 0
22593
+ maxbr: ((_o = encodings[0]) === null || _o === void 0 ? void 0 : _o.maxBitrate) ? encodings[0].maxBitrate / 1000 : 0
22594
22594
  });
22595
22595
  }
22596
- } else if (track.codec && isSVCCodec(track.codec) && ((_o = encodings[0]) === null || _o === void 0 ? void 0 : _o.maxBitrate)) {
22596
+ } else if (track.codec && isSVCCodec(track.codec) && ((_p = encodings[0]) === null || _p === void 0 ? void 0 : _p.maxBitrate)) {
22597
22597
  this.engine.publisher.setTrackCodecBitrate({
22598
22598
  cid: req.cid,
22599
22599
  codec: track.codec,