vani-meeting-client-native 0.3.2 → 0.3.3
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.
|
@@ -413,6 +413,7 @@ var CommunicationHandler = /** @class */ (function () {
|
|
|
413
413
|
var _this = this;
|
|
414
414
|
var _a;
|
|
415
415
|
var oldTrack = this.getLocalTrackById(track.trackId);
|
|
416
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("addUpdateLocalTrack", oldTrack);
|
|
416
417
|
if (oldTrack) {
|
|
417
418
|
oldTrack.updateTrackWithNewData(track);
|
|
418
419
|
track = oldTrack;
|
|
@@ -434,6 +435,7 @@ var CommunicationHandler = /** @class */ (function () {
|
|
|
434
435
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("No Video Handler While Sending Track");
|
|
435
436
|
}
|
|
436
437
|
if (this.isStartAndSetupWithServerCalled) {
|
|
438
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("Call Send Track", track);
|
|
437
439
|
(_a = this.videoCallHandler) === null || _a === void 0 ? void 0 : _a.sendTrack(track);
|
|
438
440
|
}
|
|
439
441
|
this.emitMessageToSource(VaniEvent.OnTrack, track);
|
|
@@ -184,7 +184,7 @@ var UserMediaHandler = /** @class */ (function (_super) {
|
|
|
184
184
|
})
|
|
185
185
|
.catch(function (error) {
|
|
186
186
|
var _a;
|
|
187
|
-
log
|
|
187
|
+
console.log(error);
|
|
188
188
|
(_a = _this.communicationHandler) === null || _a === void 0 ? void 0 : _a.emitMessageToSource(VaniEvent.OnPermissionError, error);
|
|
189
189
|
_this.isScreenShareFetchInProgress = false;
|
|
190
190
|
});
|
|
@@ -311,6 +311,7 @@ var UserMediaHandler = /** @class */ (function (_super) {
|
|
|
311
311
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log(userMediaPayload);
|
|
312
312
|
(new DynamicLibHelper()).getMediaDevicesVariable(this.meetingStartRequest).getUserMedia(userMediaPayload)
|
|
313
313
|
.then(function (stream) {
|
|
314
|
+
_this.meetingStartRequest && _this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On Got Stream", stream);
|
|
314
315
|
_this.onStreamGot(stream, isAudioRequired, isVideoRequired, shouldAddTrackImmediately);
|
|
315
316
|
})
|
|
316
317
|
.catch(function (error) {
|
|
@@ -351,13 +352,16 @@ var UserMediaHandler = /** @class */ (function (_super) {
|
|
|
351
352
|
}
|
|
352
353
|
}
|
|
353
354
|
catch (err) {
|
|
355
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On Got Stream error", err);
|
|
354
356
|
}
|
|
355
357
|
try {
|
|
356
358
|
if (!stream || (isForAudio === false && isForVideo === false)) {
|
|
357
359
|
this.isVideoAudioFetchInProgress = false;
|
|
360
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("No No Stream return");
|
|
358
361
|
return [2 /*return*/];
|
|
359
362
|
}
|
|
360
363
|
if (!this.communicationHandler.getSelfParticipant()) {
|
|
364
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("No Participant return");
|
|
361
365
|
return [2 /*return*/];
|
|
362
366
|
}
|
|
363
367
|
permissionApprovedFor = [];
|
|
@@ -410,6 +414,7 @@ var UserMediaHandler = /** @class */ (function (_super) {
|
|
|
410
414
|
this.registerForDeviceChange();
|
|
411
415
|
}
|
|
412
416
|
catch (er) {
|
|
417
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On Got Stream error 306", er);
|
|
413
418
|
}
|
|
414
419
|
return [2 /*return*/];
|
|
415
420
|
});
|
|
@@ -453,13 +458,16 @@ var UserMediaHandler = /** @class */ (function (_super) {
|
|
|
453
458
|
UserMediaHandler.prototype.onTrack = function (trackStream, trackKind, shouldAddTrackImmediately) {
|
|
454
459
|
var _a, _b, _c;
|
|
455
460
|
try {
|
|
461
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On Track Called");
|
|
456
462
|
var selfParticpant = (_a = this.communicationHandler) === null || _a === void 0 ? void 0 : _a.getSelfParticipant();
|
|
457
463
|
if (selfParticpant) {
|
|
458
464
|
var track = new Track(selfParticpant, true, trackKind, trackStream);
|
|
459
465
|
if (!shouldAddTrackImmediately) {
|
|
466
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("Emit On Track From User Media");
|
|
460
467
|
(_b = this.communicationHandler) === null || _b === void 0 ? void 0 : _b.emitMessageToSource(VaniEvent.OnTrack, track);
|
|
461
468
|
}
|
|
462
469
|
else {
|
|
470
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("onTrack addUpdateLocalTrack");
|
|
463
471
|
(_c = this.communicationHandler) === null || _c === void 0 ? void 0 : _c.addUpdateLocalTrack(track);
|
|
464
472
|
}
|
|
465
473
|
}
|
|
@@ -406,11 +406,12 @@ var SFUHandler = /** @class */ (function (_super) {
|
|
|
406
406
|
return __generator(this, function (_f) {
|
|
407
407
|
switch (_f.label) {
|
|
408
408
|
case 0:
|
|
409
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On Send Track - ", this.sendTransport ? true : false);
|
|
409
410
|
if (!this.sendTransport) {
|
|
410
411
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("No Send Transport", track);
|
|
411
412
|
return [2 /*return*/];
|
|
412
413
|
}
|
|
413
|
-
if (!(track && track.track)) return [3 /*break*/,
|
|
414
|
+
if (!(track && track.track)) return [3 /*break*/, 5];
|
|
414
415
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("Inside send Track");
|
|
415
416
|
producer = this.producers.find(function (producer) { return producer.appData.trackId === track.trackId; });
|
|
416
417
|
if (producer && producer.closed === false && ((_a = this.meetingStartRequest) === null || _a === void 0 ? void 0 : _a.isMobileApp)) {
|
|
@@ -465,7 +466,11 @@ var SFUHandler = /** @class */ (function (_super) {
|
|
|
465
466
|
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("On webcamProducer not created");
|
|
466
467
|
}
|
|
467
468
|
_f.label = 4;
|
|
468
|
-
case 4: return [
|
|
469
|
+
case 4: return [3 /*break*/, 6];
|
|
470
|
+
case 5:
|
|
471
|
+
this.meetingStartRequest && this.meetingStartRequest.logLevel === LogLevel.Debug && console.log("Invalid track", track);
|
|
472
|
+
_f.label = 6;
|
|
473
|
+
case 6: return [2 /*return*/];
|
|
469
474
|
}
|
|
470
475
|
});
|
|
471
476
|
});
|