mediasoup 3.12.4 → 3.12.5

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.
@@ -90,7 +90,7 @@ class Worker extends EnhancedEventEmitter_1.EnhancedEventEmitter {
90
90
  // options
91
91
  {
92
92
  env: {
93
- MEDIASOUP_VERSION: '3.12.4',
93
+ MEDIASOUP_VERSION: '3.12.5',
94
94
  // Let the worker process inherit all environment variables, useful
95
95
  // if a custom and not in the path GCC is used so the user can set
96
96
  // LD_LIBRARY_PATH environment variable for runtime.
@@ -10,7 +10,7 @@ export { types };
10
10
  /**
11
11
  * Expose mediasoup version.
12
12
  */
13
- export declare const version = "3.12.4";
13
+ export declare const version = "3.12.5";
14
14
  /**
15
15
  * Expose parseScalabilityMode() function.
16
16
  */
package/node/lib/index.js CHANGED
@@ -11,7 +11,7 @@ exports.types = types;
11
11
  /**
12
12
  * Expose mediasoup version.
13
13
  */
14
- exports.version = '3.12.4';
14
+ exports.version = '3.12.5';
15
15
  /**
16
16
  * Expose parseScalabilityMode() function.
17
17
  */
@@ -11,7 +11,7 @@ test('mediasoup.getSupportedRtpCapabilities() returns the mediasoup RTP capabili
11
11
  rtpCapabilities.codecs = 'bar';
12
12
  const rtpCapabilities2 = getSupportedRtpCapabilities();
13
13
  expect(rtpCapabilities2).not.toEqual(rtpCapabilities);
14
- }, 500);
14
+ });
15
15
  test('parseScalabilityMode() works', () => {
16
16
  expect(parseScalabilityMode('L1T3'))
17
17
  .toEqual({ spatialLayers: 1, temporalLayers: 3, ksvc: false });
@@ -33,4 +33,4 @@ test('parseScalabilityMode() works', () => {
33
33
  .toEqual({ spatialLayers: 1, temporalLayers: 1, ksvc: false });
34
34
  expect(parseScalabilityMode('L4T7_KEY_SHIFT'))
35
35
  .toEqual({ spatialLayers: 4, temporalLayers: 7, ksvc: true });
36
- }, 500);
36
+ });
@@ -1,23 +1,23 @@
1
- export * from './Worker';
2
- export * from './WebRtcServer';
3
- export * from './Router';
4
- export * from './Transport';
5
- export * from './WebRtcTransport';
6
- export * from './PlainTransport';
7
- export * from './PipeTransport';
8
- export * from './DirectTransport';
9
- export * from './Producer';
10
- export * from './Consumer';
11
- export * from './DataProducer';
12
- export * from './DataConsumer';
13
- export * from './RtpObserver';
14
- export * from './ActiveSpeakerObserver';
15
- export * from './AudioLevelObserver';
16
- export * from './RtpParameters';
17
- export * from './SctpParameters';
18
- export * from './SrtpParameters';
1
+ export type * from './Worker';
2
+ export type * from './WebRtcServer';
3
+ export type * from './Router';
4
+ export type * from './Transport';
5
+ export type * from './WebRtcTransport';
6
+ export type * from './PlainTransport';
7
+ export type * from './PipeTransport';
8
+ export type * from './DirectTransport';
9
+ export type * from './Producer';
10
+ export type * from './Consumer';
11
+ export type * from './DataProducer';
12
+ export type * from './DataConsumer';
13
+ export type * from './RtpObserver';
14
+ export type * from './ActiveSpeakerObserver';
15
+ export type * from './AudioLevelObserver';
16
+ export type * from './RtpParameters';
17
+ export type * from './SctpParameters';
18
+ export type * from './SrtpParameters';
19
19
  export * from './errors';
20
- export { ScalabilityMode } from './scalabilityModes';
20
+ export type { ScalabilityMode } from './scalabilityModes';
21
21
  export type AppData = {
22
22
  [key: string]: unknown;
23
23
  };
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,UAAU,CAAC;AACzB,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,MAAM,OAAO,GACnB;IACC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACvB,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,mBAAmB,UAAU,CAAC;AAC9B,mBAAmB,gBAAgB,CAAC;AACpC,mBAAmB,UAAU,CAAC;AAC9B,mBAAmB,aAAa,CAAC;AACjC,mBAAmB,mBAAmB,CAAC;AACvC,mBAAmB,kBAAkB,CAAC;AACtC,mBAAmB,iBAAiB,CAAC;AACrC,mBAAmB,mBAAmB,CAAC;AACvC,mBAAmB,YAAY,CAAC;AAChC,mBAAmB,YAAY,CAAC;AAChC,mBAAmB,gBAAgB,CAAC;AACpC,mBAAmB,gBAAgB,CAAC;AACpC,mBAAmB,eAAe,CAAC;AACnC,mBAAmB,yBAAyB,CAAC;AAC7C,mBAAmB,sBAAsB,CAAC;AAC1C,mBAAmB,iBAAiB,CAAC;AACrC,mBAAmB,kBAAkB,CAAC;AACtC,mBAAmB,kBAAkB,CAAC;AAEtC,cAAc,UAAU,CAAC;AACzB,YAAY,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAE1D,MAAM,MAAM,OAAO,GACnB;IACC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACvB,CAAC"}
package/node/lib/types.js CHANGED
@@ -14,22 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./Worker"), exports);
18
- __exportStar(require("./WebRtcServer"), exports);
19
- __exportStar(require("./Router"), exports);
20
- __exportStar(require("./Transport"), exports);
21
- __exportStar(require("./WebRtcTransport"), exports);
22
- __exportStar(require("./PlainTransport"), exports);
23
- __exportStar(require("./PipeTransport"), exports);
24
- __exportStar(require("./DirectTransport"), exports);
25
- __exportStar(require("./Producer"), exports);
26
- __exportStar(require("./Consumer"), exports);
27
- __exportStar(require("./DataProducer"), exports);
28
- __exportStar(require("./DataConsumer"), exports);
29
- __exportStar(require("./RtpObserver"), exports);
30
- __exportStar(require("./ActiveSpeakerObserver"), exports);
31
- __exportStar(require("./AudioLevelObserver"), exports);
32
- __exportStar(require("./RtpParameters"), exports);
33
- __exportStar(require("./SctpParameters"), exports);
34
- __exportStar(require("./SrtpParameters"), exports);
17
+ // We cannot export only the type of error classes because those are useless.
35
18
  __exportStar(require("./errors"), exports);
package/npm-scripts.mjs CHANGED
@@ -103,15 +103,8 @@ async function run()
103
103
 
104
104
  case 'typescript:watch':
105
105
  {
106
- // NOTE: Load dep on demand since it's a devDependency.
107
- const { TscWatchClient } = await import('tsc-watch/client.js');
108
-
109
- const watch = new TscWatchClient();
110
-
111
106
  deleteNodeLib();
112
-
113
- watch.on('success', replaceVersion);
114
- watch.start('--project', 'node', '--pretty');
107
+ executeCmd('tsc --project node --watch');
115
108
 
116
109
  break;
117
110
  }
@@ -270,19 +263,24 @@ function replaceVersion()
270
263
  {
271
264
  logInfo('replaceVersion()');
272
265
 
273
- const files =
274
- [
275
- 'node/lib/index.js',
276
- 'node/lib/index.d.ts',
277
- 'node/lib/Worker.js'
278
- ];
266
+ const files = fs.readdirSync('node/lib',
267
+ {
268
+ withFileTypes : true,
269
+ recursive : true
270
+ });
279
271
 
280
272
  for (const file of files)
281
273
  {
282
- const text = fs.readFileSync(file, { encoding: 'utf8' });
274
+ if (!file.isFile())
275
+ {
276
+ continue;
277
+ }
278
+
279
+ const filePath = path.join('node/lib', file.name);
280
+ const text = fs.readFileSync(filePath, { encoding: 'utf8' });
283
281
  const result = text.replace(/__MEDIASOUP_VERSION__/g, PKG.version);
284
282
 
285
- fs.writeFileSync(file, result, { encoding: 'utf8' });
283
+ fs.writeFileSync(filePath, result, { encoding: 'utf8' });
286
284
  }
287
285
  }
288
286
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mediasoup",
3
- "version": "3.12.4",
3
+ "version": "3.12.5",
4
4
  "description": "Cutting Edge WebRTC Video Conferencing",
5
5
  "contributors": [
6
6
  "Iñaki Baz Castillo <ibc@aliax.net> (https://inakibaz.me)",
@@ -90,7 +90,7 @@
90
90
  "debug": "^4.3.4",
91
91
  "h264-profile-level-id": "^1.0.1",
92
92
  "node-fetch": "^3.3.1",
93
- "supports-color": "^9.3.1",
93
+ "supports-color": "^9.4.0",
94
94
  "tar": "^6.1.15",
95
95
  "uuid": "^9.0.0"
96
96
  },
@@ -100,17 +100,16 @@
100
100
  "@types/jest": "^29.5.2",
101
101
  "@types/node": "^18.16.18",
102
102
  "@types/uuid": "^9.0.2",
103
- "@typescript-eslint/eslint-plugin": "^5.60.0",
104
- "@typescript-eslint/parser": "^5.60.0",
105
- "eslint": "^8.43.0",
103
+ "@typescript-eslint/eslint-plugin": "^5.61.0",
104
+ "@typescript-eslint/parser": "^5.61.0",
105
+ "eslint": "^8.44.0",
106
106
  "eslint-plugin-jest": "^27.2.2",
107
- "jest": "^29.5.0",
108
- "marked": "^5.1.0",
107
+ "jest": "^29.6.1",
108
+ "marked": "^5.1.1",
109
109
  "open-cli": "^7.2.0",
110
110
  "pick-port": "^1.0.1",
111
111
  "sctp": "^1.0.0",
112
- "ts-jest": "^29.1.0",
113
- "tsc-watch": "^6.0.4",
114
- "typescript": "^5.1.3"
112
+ "ts-jest": "^29.1.1",
113
+ "typescript": "^5.1.6"
115
114
  }
116
115
  }
@@ -212,6 +212,8 @@ namespace RTC
212
212
 
213
213
  data.append(std::to_string(this->bufferedAmount));
214
214
  data.append("}");
215
+
216
+ this->shared->channelNotifier->Emit(this->id, "bufferedamountlow", data);
215
217
  }
216
218
  // Force the trigger of 'bufferedamountlow' once there is less or same
217
219
  // buffered data than the given threshold.