[mirotalksfu] - update dep. fix typo
هذا الالتزام موجود في:
@@ -53,7 +53,7 @@ Change the `announcedIp` with your `Server public IPv4` on `app/src/config.js`
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
Set the `inbound rules` if you have the Firewall enalbled
|
Set the `inbound rules` if you have the Firewall enabled
|
||||||
|
|
||||||
| Port range | Protocol | Source | Description |
|
| Port range | Protocol | Source | Description |
|
||||||
| ----------- | -------- | --------- | ------------------- |
|
| ----------- | -------- | --------- | ------------------- |
|
||||||
@@ -78,7 +78,7 @@ Check if is correctly installed: https://your.domain.name:3010
|
|||||||
|
|
||||||

|

|
||||||
|
|
||||||
Using [PM2](https://pm2.keymetrics.io) to run it as deamon
|
Using [PM2](https://pm2.keymetrics.io) to run it as daemon
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ npm install -g pm2
|
$ npm install -g pm2
|
||||||
|
|||||||
@@ -31,7 +31,7 @@
|
|||||||
"express": "4.18.2",
|
"express": "4.18.2",
|
||||||
"httpolyglot": "0.1.2",
|
"httpolyglot": "0.1.2",
|
||||||
"mediasoup": "3.10.11",
|
"mediasoup": "3.10.11",
|
||||||
"mediasoup-client": "3.6.57",
|
"mediasoup-client": "3.6.58",
|
||||||
"ngrok": "4.3.3",
|
"ngrok": "4.3.3",
|
||||||
"qs": "6.11.0",
|
"qs": "6.11.0",
|
||||||
"@sentry/node": "7.16.0",
|
"@sentry/node": "7.16.0",
|
||||||
|
|||||||
@@ -7047,6 +7047,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
||||||
await this._pc.setLocalDescription(offer);
|
await this._pc.setLocalDescription(offer);
|
||||||
@@ -7058,6 +7059,7 @@
|
|||||||
this._assertSendDirection();
|
this._assertSendDirection();
|
||||||
logger.debug('resumeSending() [localId:%s]', localId);
|
logger.debug('resumeSending() [localId:%s]', localId);
|
||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
|
this._remoteSdp.resumeSendingMediaSection(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'sendonly';
|
transceiver.direction = 'sendonly';
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
@@ -7238,6 +7240,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -7253,6 +7256,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'recvonly';
|
transceiver.direction = 'recvonly';
|
||||||
|
this._remoteSdp.resumeReceivingMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -8154,6 +8158,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
||||||
await this._pc.setLocalDescription(offer);
|
await this._pc.setLocalDescription(offer);
|
||||||
@@ -8168,6 +8173,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'sendonly';
|
transceiver.direction = 'sendonly';
|
||||||
|
this._remoteSdp.resumeSendingMediaSection(localId);
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
logger.debug('resumeSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
logger.debug('resumeSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
||||||
await this._pc.setLocalDescription(offer);
|
await this._pc.setLocalDescription(offer);
|
||||||
@@ -8337,6 +8343,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -8352,6 +8359,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'recvonly';
|
transceiver.direction = 'recvonly';
|
||||||
|
this._remoteSdp.resumeReceivingMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -9956,6 +9964,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
logger.debug('pauseSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
||||||
await this._pc.setLocalDescription(offer);
|
await this._pc.setLocalDescription(offer);
|
||||||
@@ -9970,6 +9979,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'sendonly';
|
transceiver.direction = 'sendonly';
|
||||||
|
this._remoteSdp.resumeSendingMediaSection(localId);
|
||||||
const offer = await this._pc.createOffer();
|
const offer = await this._pc.createOffer();
|
||||||
logger.debug('resumeSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
logger.debug('resumeSending() | calling pc.setLocalDescription() [offer:%o]', offer);
|
||||||
await this._pc.setLocalDescription(offer);
|
await this._pc.setLocalDescription(offer);
|
||||||
@@ -10145,6 +10155,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'inactive';
|
transceiver.direction = 'inactive';
|
||||||
|
this._remoteSdp.pauseMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('pauseReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -10160,6 +10171,7 @@
|
|||||||
const transceiver = this._mapMidTransceiver.get(localId);
|
const transceiver = this._mapMidTransceiver.get(localId);
|
||||||
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
if (!transceiver) throw new Error('associated RTCRtpTransceiver not found');
|
||||||
transceiver.direction = 'recvonly';
|
transceiver.direction = 'recvonly';
|
||||||
|
this._remoteSdp.resumeReceivingMediaSection(localId);
|
||||||
}
|
}
|
||||||
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
const offer = { type: 'offer', sdp: this._remoteSdp.getSdp() };
|
||||||
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
logger.debug('resumeReceiving() | calling pc.setRemoteDescription() [offer:%o]', offer);
|
||||||
@@ -10443,18 +10455,11 @@
|
|||||||
this._mediaObject.iceUfrag = iceParameters.usernameFragment;
|
this._mediaObject.iceUfrag = iceParameters.usernameFragment;
|
||||||
this._mediaObject.icePwd = iceParameters.password;
|
this._mediaObject.icePwd = iceParameters.password;
|
||||||
}
|
}
|
||||||
disable() {
|
pause() {
|
||||||
this._mediaObject.direction = 'inactive';
|
this._mediaObject.direction = 'inactive';
|
||||||
delete this._mediaObject.ext;
|
|
||||||
delete this._mediaObject.ssrcs;
|
|
||||||
delete this._mediaObject.ssrcGroups;
|
|
||||||
delete this._mediaObject.simulcast;
|
|
||||||
delete this._mediaObject.simulcast_03;
|
|
||||||
delete this._mediaObject.rids;
|
|
||||||
}
|
}
|
||||||
close() {
|
disable() {
|
||||||
this._mediaObject.direction = 'inactive';
|
this.pause();
|
||||||
this._mediaObject.port = 0;
|
|
||||||
delete this._mediaObject.ext;
|
delete this._mediaObject.ext;
|
||||||
delete this._mediaObject.ssrcs;
|
delete this._mediaObject.ssrcs;
|
||||||
delete this._mediaObject.ssrcGroups;
|
delete this._mediaObject.ssrcGroups;
|
||||||
@@ -10463,6 +10468,10 @@
|
|||||||
delete this._mediaObject.rids;
|
delete this._mediaObject.rids;
|
||||||
delete this._mediaObject.extmapAllowMixed;
|
delete this._mediaObject.extmapAllowMixed;
|
||||||
}
|
}
|
||||||
|
close() {
|
||||||
|
this.disable();
|
||||||
|
this._mediaObject.port = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
exports.MediaSection = MediaSection;
|
exports.MediaSection = MediaSection;
|
||||||
class AnswerMediaSection extends MediaSection {
|
class AnswerMediaSection extends MediaSection {
|
||||||
@@ -10669,6 +10678,9 @@
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
resume() {
|
||||||
|
this._mediaObject.direction = 'recvonly';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
exports.AnswerMediaSection = AnswerMediaSection;
|
exports.AnswerMediaSection = AnswerMediaSection;
|
||||||
class OfferMediaSection extends MediaSection {
|
class OfferMediaSection extends MediaSection {
|
||||||
@@ -10814,6 +10826,9 @@
|
|||||||
// Always 'actpass'.
|
// Always 'actpass'.
|
||||||
this._mediaObject.setup = 'actpass';
|
this._mediaObject.setup = 'actpass';
|
||||||
}
|
}
|
||||||
|
resume() {
|
||||||
|
this._mediaObject.direction = 'sendonly';
|
||||||
|
}
|
||||||
planBReceive({ offerRtpParameters, streamId, trackId }) {
|
planBReceive({ offerRtpParameters, streamId, trackId }) {
|
||||||
const encoding = offerRtpParameters.encodings[0];
|
const encoding = offerRtpParameters.encodings[0];
|
||||||
const ssrc = encoding.ssrc;
|
const ssrc = encoding.ssrc;
|
||||||
@@ -11102,20 +11117,24 @@
|
|||||||
this._replaceMediaSection(mediaSection);
|
this._replaceMediaSection(mediaSection);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
disableMediaSection(mid) {
|
pauseMediaSection(mid) {
|
||||||
const idx = this._midToIndex.get(mid);
|
const mediaSection = this._findMediaSection(mid);
|
||||||
if (idx === undefined) {
|
mediaSection.pause();
|
||||||
throw new Error(`no media section found with mid '${mid}'`);
|
|
||||||
}
|
}
|
||||||
const mediaSection = this._mediaSections[idx];
|
resumeSendingMediaSection(mid) {
|
||||||
|
const mediaSection = this._findMediaSection(mid);
|
||||||
|
mediaSection.resume();
|
||||||
|
}
|
||||||
|
resumeReceivingMediaSection(mid) {
|
||||||
|
const mediaSection = this._findMediaSection(mid);
|
||||||
|
mediaSection.resume();
|
||||||
|
}
|
||||||
|
disableMediaSection(mid) {
|
||||||
|
const mediaSection = this._findMediaSection(mid);
|
||||||
mediaSection.disable();
|
mediaSection.disable();
|
||||||
}
|
}
|
||||||
closeMediaSection(mid) {
|
closeMediaSection(mid) {
|
||||||
const idx = this._midToIndex.get(mid);
|
const mediaSection = this._findMediaSection(mid);
|
||||||
if (idx === undefined) {
|
|
||||||
throw new Error(`no media section found with mid '${mid}'`);
|
|
||||||
}
|
|
||||||
const mediaSection = this._mediaSections[idx];
|
|
||||||
// NOTE: Closing the first m section is a pain since it invalidates the
|
// NOTE: Closing the first m section is a pain since it invalidates the
|
||||||
// bundled transport, so let's avoid it.
|
// bundled transport, so let's avoid it.
|
||||||
if (mid === this._firstMid) {
|
if (mid === this._firstMid) {
|
||||||
@@ -11207,6 +11226,13 @@
|
|||||||
this._sdpObject.media[idx] = newMediaSection.getObject();
|
this._sdpObject.media[idx] = newMediaSection.getObject();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
_findMediaSection(mid) {
|
||||||
|
const idx = this._midToIndex.get(mid);
|
||||||
|
if (idx === undefined) {
|
||||||
|
throw new Error(`no media section found with mid '${mid}'`);
|
||||||
|
}
|
||||||
|
return this._mediaSections[idx];
|
||||||
|
}
|
||||||
_regenerateBundleMids() {
|
_regenerateBundleMids() {
|
||||||
if (!this._dtlsParameters) return;
|
if (!this._dtlsParameters) return;
|
||||||
this._sdpObject.groups[0].mids = this._mediaSections
|
this._sdpObject.groups[0].mids = this._mediaSections
|
||||||
@@ -11751,7 +11777,7 @@
|
|||||||
/**
|
/**
|
||||||
* Expose mediasoup-client version.
|
* Expose mediasoup-client version.
|
||||||
*/
|
*/
|
||||||
exports.version = '3.6.57';
|
exports.version = '3.6.58';
|
||||||
/**
|
/**
|
||||||
* Expose parseScalabilityMode() function.
|
* Expose parseScalabilityMode() function.
|
||||||
*/
|
*/
|
||||||
|
|||||||
المرجع في مشكلة جديدة
حظر مستخدم