@stream-io/video-client 0.7.7 → 0.7.8
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.
- package/CHANGELOG.md +7 -0
- package/dist/index.browser.es.js +358 -4
- package/dist/index.browser.es.js.map +1 -1
- package/dist/index.cjs.js +359 -3
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +358 -4
- package/dist/index.es.js.map +1 -1
- package/dist/src/Call.d.ts +12 -0
- package/dist/src/StreamSfuClient.d.ts +2 -0
- package/dist/src/devices/InputMediaDeviceManager.d.ts +1 -1
- package/dist/src/devices/MicrophoneManager.d.ts +17 -0
- package/dist/src/gen/coordinator/index.d.ts +96 -34
- package/dist/src/gen/video/sfu/signal_rpc/signal.client.d.ts +17 -1
- package/dist/src/gen/video/sfu/signal_rpc/signal.d.ts +76 -0
- package/package.json +6 -5
- package/src/Call.ts +22 -0
- package/src/StreamSfuClient.ts +20 -0
- package/src/devices/InputMediaDeviceManager.ts +2 -1
- package/src/devices/MicrophoneManager.ts +123 -1
- package/src/devices/__tests__/MicrophoneManager.test.ts +121 -4
- package/src/devices/__tests__/MicrophoneManagerRN.test.ts +24 -0
- package/src/devices/__tests__/mocks.ts +17 -1
- package/src/gen/coordinator/index.ts +102 -49
- package/src/gen/google/protobuf/struct.ts +1 -1
- package/src/gen/google/protobuf/timestamp.ts +1 -1
- package/src/gen/video/sfu/event/events.ts +1 -1
- package/src/gen/video/sfu/models/models.ts +1 -1
- package/src/gen/video/sfu/signal_rpc/signal.client.ts +47 -1
- package/src/gen/video/sfu/signal_rpc/signal.ts +369 -1
- package/src/helpers/sound-detector.ts +3 -1
|
@@ -1,8 +1,14 @@
|
|
|
1
|
+
import { afterEach, beforeEach, describe, expect, it, Mock, vi } from 'vitest';
|
|
2
|
+
import type { INoiseCancellation } from '@stream-io/audio-filters-web';
|
|
1
3
|
import { Call } from '../../Call';
|
|
2
4
|
import { StreamClient } from '../../coordinator/connection/client';
|
|
5
|
+
import { sleep } from '../../coordinator/connection/utils';
|
|
6
|
+
import {
|
|
7
|
+
NoiseCancellationSettingsModeEnum,
|
|
8
|
+
OwnCapability,
|
|
9
|
+
} from '../../gen/coordinator';
|
|
10
|
+
import { TrackType } from '../../gen/video/sfu/models/models';
|
|
3
11
|
import { CallingState, StreamVideoWriteableStateStore } from '../../store';
|
|
4
|
-
|
|
5
|
-
import { afterEach, beforeEach, describe, expect, it, Mock, vi } from 'vitest';
|
|
6
12
|
import {
|
|
7
13
|
mockAudioDevices,
|
|
8
14
|
mockAudioStream,
|
|
@@ -10,14 +16,12 @@ import {
|
|
|
10
16
|
mockDeviceIds$,
|
|
11
17
|
} from './mocks';
|
|
12
18
|
import { getAudioStream } from '../devices';
|
|
13
|
-
import { TrackType } from '../../gen/video/sfu/models/models';
|
|
14
19
|
import { MicrophoneManager } from '../MicrophoneManager';
|
|
15
20
|
import { of } from 'rxjs';
|
|
16
21
|
import {
|
|
17
22
|
createSoundDetector,
|
|
18
23
|
SoundStateChangeHandler,
|
|
19
24
|
} from '../../helpers/sound-detector';
|
|
20
|
-
import { OwnCapability } from '../../gen/coordinator';
|
|
21
25
|
|
|
22
26
|
vi.mock('../devices.ts', () => {
|
|
23
27
|
console.log('MOCKING devices API');
|
|
@@ -45,6 +49,22 @@ vi.mock('../../Call.ts', () => {
|
|
|
45
49
|
};
|
|
46
50
|
});
|
|
47
51
|
|
|
52
|
+
class NoiseCancellationStub implements INoiseCancellation {
|
|
53
|
+
private listeners: { [event: string]: Array<() => void> } = {};
|
|
54
|
+
|
|
55
|
+
isSupported = () => true;
|
|
56
|
+
init = () => Promise.resolve(undefined);
|
|
57
|
+
enable = () => this.listeners['change']?.forEach((l) => l(true));
|
|
58
|
+
disable = () => this.listeners['change']?.forEach((l) => l(false));
|
|
59
|
+
dispose = () => Promise.resolve(undefined);
|
|
60
|
+
toFilter = () => async (ms: MediaStream) => ms;
|
|
61
|
+
on = (event, callback) => {
|
|
62
|
+
(this.listeners[event] ??= []).push(callback);
|
|
63
|
+
return () => {};
|
|
64
|
+
};
|
|
65
|
+
off = () => {};
|
|
66
|
+
}
|
|
67
|
+
|
|
48
68
|
describe('MicrophoneManager', () => {
|
|
49
69
|
let manager: MicrophoneManager;
|
|
50
70
|
|
|
@@ -188,6 +208,103 @@ describe('MicrophoneManager', () => {
|
|
|
188
208
|
expect(manager['stopSpeakingWhileMutedDetection']).toHaveBeenCalled();
|
|
189
209
|
});
|
|
190
210
|
|
|
211
|
+
describe('Noise Cancellation', () => {
|
|
212
|
+
it('should register filter if all preconditions are met', async () => {
|
|
213
|
+
const call = manager['call'];
|
|
214
|
+
call.state.setCallingState(CallingState.IDLE);
|
|
215
|
+
const registerFilter = vi.spyOn(manager, 'registerFilter');
|
|
216
|
+
const noiseCancellation = new NoiseCancellationStub();
|
|
217
|
+
const noiseCancellationEnable = vi.spyOn(noiseCancellation, 'enable');
|
|
218
|
+
await manager.enableNoiseCancellation(noiseCancellation);
|
|
219
|
+
|
|
220
|
+
expect(registerFilter).toBeCalled();
|
|
221
|
+
expect(noiseCancellationEnable).not.toBeCalled();
|
|
222
|
+
});
|
|
223
|
+
|
|
224
|
+
it('should unregister filter when disabling noise cancellation', async () => {
|
|
225
|
+
const noiseCancellation = new NoiseCancellationStub();
|
|
226
|
+
await manager.enableNoiseCancellation(noiseCancellation);
|
|
227
|
+
await manager.disableNoiseCancellation();
|
|
228
|
+
const call = manager['call'];
|
|
229
|
+
expect(call.notifyNoiseCancellationStopped).toBeCalled();
|
|
230
|
+
});
|
|
231
|
+
|
|
232
|
+
it('should throw when own capabilities are missing', async () => {
|
|
233
|
+
const call = manager['call'];
|
|
234
|
+
call.state.setOwnCapabilities([]);
|
|
235
|
+
|
|
236
|
+
await expect(() =>
|
|
237
|
+
manager.enableNoiseCancellation(new NoiseCancellationStub()),
|
|
238
|
+
).rejects.toThrow();
|
|
239
|
+
});
|
|
240
|
+
|
|
241
|
+
it('should throw when noise cancellation is disabled in call settings', async () => {
|
|
242
|
+
const call = manager['call'];
|
|
243
|
+
call.state.setOwnCapabilities([OwnCapability.ENABLE_NOISE_CANCELLATION]);
|
|
244
|
+
call.state.updateFromCallResponse({
|
|
245
|
+
// @ts-expect-error partial data
|
|
246
|
+
audio: {
|
|
247
|
+
noise_cancellation: {
|
|
248
|
+
mode: NoiseCancellationSettingsModeEnum.DISABLED,
|
|
249
|
+
},
|
|
250
|
+
},
|
|
251
|
+
});
|
|
252
|
+
await expect(() =>
|
|
253
|
+
manager.enableNoiseCancellation(new NoiseCancellationStub()),
|
|
254
|
+
).rejects.toThrow();
|
|
255
|
+
});
|
|
256
|
+
|
|
257
|
+
it('should automatically enable noise noise suppression after joining a call', async () => {
|
|
258
|
+
const call = manager['call'];
|
|
259
|
+
call.state.setCallingState(CallingState.IDLE); // reset state
|
|
260
|
+
call.state.updateFromCallResponse({
|
|
261
|
+
settings: {
|
|
262
|
+
// @ts-expect-error - partial data
|
|
263
|
+
audio: {
|
|
264
|
+
noise_cancellation: {
|
|
265
|
+
mode: NoiseCancellationSettingsModeEnum.AUTO_ON,
|
|
266
|
+
},
|
|
267
|
+
},
|
|
268
|
+
},
|
|
269
|
+
});
|
|
270
|
+
|
|
271
|
+
const noiseCancellation = new NoiseCancellationStub();
|
|
272
|
+
const noiseCancellationEnable = vi.spyOn(noiseCancellation, 'enable');
|
|
273
|
+
await manager.enableNoiseCancellation(noiseCancellation);
|
|
274
|
+
|
|
275
|
+
expect(noiseCancellationEnable).not.toBeCalled();
|
|
276
|
+
|
|
277
|
+
call.state.setCallingState(CallingState.JOINED);
|
|
278
|
+
|
|
279
|
+
// it is quite hard to test the "detached" callingState$ subscription
|
|
280
|
+
// with the current tools and architecture.
|
|
281
|
+
// that is why we go with the good old sleep
|
|
282
|
+
await sleep(25);
|
|
283
|
+
|
|
284
|
+
expect(noiseCancellationEnable).toBeCalled();
|
|
285
|
+
expect(call.notifyNoiseCancellationStarting).toBeCalled();
|
|
286
|
+
});
|
|
287
|
+
|
|
288
|
+
it('should automatically disable noise suppression after leaving the call', async () => {
|
|
289
|
+
const call = manager['call'];
|
|
290
|
+
const noiseCancellation = new NoiseCancellationStub();
|
|
291
|
+
const noiseSuppressionDisable = vi.spyOn(noiseCancellation, 'disable');
|
|
292
|
+
await manager.enableNoiseCancellation(noiseCancellation);
|
|
293
|
+
|
|
294
|
+
expect(noiseSuppressionDisable).not.toBeCalled();
|
|
295
|
+
|
|
296
|
+
call.state.setCallingState(CallingState.LEFT);
|
|
297
|
+
|
|
298
|
+
// it is quite hard to test the "detached" callingState$ subscription
|
|
299
|
+
// with the current tools and architecture.
|
|
300
|
+
// that is why we go with the good old sleep
|
|
301
|
+
await sleep(25);
|
|
302
|
+
|
|
303
|
+
expect(noiseSuppressionDisable).toBeCalled();
|
|
304
|
+
expect(call.notifyNoiseCancellationStopped).toBeCalled();
|
|
305
|
+
});
|
|
306
|
+
});
|
|
307
|
+
|
|
191
308
|
afterEach(() => {
|
|
192
309
|
vi.clearAllMocks();
|
|
193
310
|
vi.resetModules();
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
|
|
2
|
+
import { INoiseCancellation } from '@stream-io/audio-filters-web';
|
|
2
3
|
import { MicrophoneManager } from '../MicrophoneManager';
|
|
3
4
|
import { Call } from '../../Call';
|
|
4
5
|
import { StreamClient } from '../../coordinator/connection/client';
|
|
@@ -119,6 +120,29 @@ describe('MicrophoneManager React Native', () => {
|
|
|
119
120
|
expect(manager['stopSpeakingWhileMutedDetection']).toHaveBeenCalled();
|
|
120
121
|
});
|
|
121
122
|
|
|
123
|
+
describe('Noise Suppression', () => {
|
|
124
|
+
it('enable: should throw an error in React Native', async () => {
|
|
125
|
+
await expect(() => {
|
|
126
|
+
return manager.enableNoiseCancellation(
|
|
127
|
+
new (class implements INoiseCancellation {
|
|
128
|
+
isSupported = () => true;
|
|
129
|
+
init = () => Promise.resolve(undefined);
|
|
130
|
+
enable = () => {};
|
|
131
|
+
disable = () => {};
|
|
132
|
+
dispose = () => Promise.resolve(undefined);
|
|
133
|
+
toFilter = () => async (ms: MediaStream) => ms;
|
|
134
|
+
on = () => () => {};
|
|
135
|
+
off = () => {};
|
|
136
|
+
})(),
|
|
137
|
+
);
|
|
138
|
+
}).rejects.toThrow();
|
|
139
|
+
});
|
|
140
|
+
|
|
141
|
+
it('disable: should throw an error in React Native', async () => {
|
|
142
|
+
await expect(() => manager.disableNoiseCancellation()).rejects.toThrow();
|
|
143
|
+
});
|
|
144
|
+
});
|
|
145
|
+
|
|
122
146
|
afterEach(() => {
|
|
123
147
|
vi.clearAllMocks();
|
|
124
148
|
vi.resetModules();
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { vi } from 'vitest';
|
|
2
2
|
import { CallingState, CallState } from '../../store';
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
NoiseCancellationSettingsModeEnum,
|
|
5
|
+
OwnCapability,
|
|
6
|
+
} from '../../gen/coordinator';
|
|
4
7
|
import { Call } from '../../Call';
|
|
5
8
|
import { Subject } from 'rxjs';
|
|
6
9
|
|
|
@@ -71,13 +74,26 @@ export const mockCall = (): Partial<Call> => {
|
|
|
71
74
|
callState.setOwnCapabilities([
|
|
72
75
|
OwnCapability.SEND_AUDIO,
|
|
73
76
|
OwnCapability.SEND_VIDEO,
|
|
77
|
+
OwnCapability.ENABLE_NOISE_CANCELLATION,
|
|
74
78
|
]);
|
|
79
|
+
callState.updateFromCallResponse({
|
|
80
|
+
settings: {
|
|
81
|
+
// @ts-expect-error partial data
|
|
82
|
+
audio: {
|
|
83
|
+
noise_cancellation: {
|
|
84
|
+
mode: NoiseCancellationSettingsModeEnum.AVAILABLE,
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
},
|
|
88
|
+
});
|
|
75
89
|
return {
|
|
76
90
|
state: callState,
|
|
77
91
|
publishVideoStream: vi.fn(),
|
|
78
92
|
publishAudioStream: vi.fn(),
|
|
79
93
|
publishScreenShareStream: vi.fn(),
|
|
80
94
|
stopPublish: vi.fn(),
|
|
95
|
+
notifyNoiseCancellationStarting: vi.fn().mockResolvedValue(undefined),
|
|
96
|
+
notifyNoiseCancellationStopped: vi.fn().mockResolvedValue(undefined),
|
|
81
97
|
};
|
|
82
98
|
};
|
|
83
99
|
|
|
@@ -86,6 +86,12 @@ export interface AudioSettings {
|
|
|
86
86
|
* @memberof AudioSettings
|
|
87
87
|
*/
|
|
88
88
|
mic_default_on: boolean;
|
|
89
|
+
/**
|
|
90
|
+
*
|
|
91
|
+
* @type {NoiseCancellationSettings}
|
|
92
|
+
* @memberof AudioSettings
|
|
93
|
+
*/
|
|
94
|
+
noise_cancellation?: NoiseCancellationSettings;
|
|
89
95
|
/**
|
|
90
96
|
*
|
|
91
97
|
* @type {boolean}
|
|
@@ -140,6 +146,12 @@ export interface AudioSettingsRequest {
|
|
|
140
146
|
* @memberof AudioSettingsRequest
|
|
141
147
|
*/
|
|
142
148
|
mic_default_on?: boolean;
|
|
149
|
+
/**
|
|
150
|
+
*
|
|
151
|
+
* @type {NoiseCancellationSettingsRequest}
|
|
152
|
+
* @memberof AudioSettingsRequest
|
|
153
|
+
*/
|
|
154
|
+
noise_cancellation?: NoiseCancellationSettingsRequest;
|
|
143
155
|
/**
|
|
144
156
|
*
|
|
145
157
|
* @type {boolean}
|
|
@@ -472,9 +484,7 @@ export interface CallEndedEvent {
|
|
|
472
484
|
*/
|
|
473
485
|
user?: UserResponse;
|
|
474
486
|
}
|
|
475
|
-
|
|
476
487
|
/**
|
|
477
|
-
*
|
|
478
488
|
* @export
|
|
479
489
|
* @interface CallEvent
|
|
480
490
|
*/
|
|
@@ -510,7 +520,6 @@ export interface CallEvent {
|
|
|
510
520
|
*/
|
|
511
521
|
type: string;
|
|
512
522
|
}
|
|
513
|
-
|
|
514
523
|
/**
|
|
515
524
|
* This event is sent when HLS broadcasting has failed
|
|
516
525
|
* @export
|
|
@@ -2099,7 +2108,6 @@ export interface ClosedCaptionEvent {
|
|
|
2099
2108
|
*/
|
|
2100
2109
|
type: string;
|
|
2101
2110
|
}
|
|
2102
|
-
|
|
2103
2111
|
/**
|
|
2104
2112
|
*
|
|
2105
2113
|
* @export
|
|
@@ -2108,10 +2116,10 @@ export interface ClosedCaptionEvent {
|
|
|
2108
2116
|
export interface CollectUserFeedbackRequest {
|
|
2109
2117
|
/**
|
|
2110
2118
|
*
|
|
2111
|
-
* @type {
|
|
2119
|
+
* @type {{ [key:string]: any }}
|
|
2112
2120
|
* @memberof CollectUserFeedbackRequest
|
|
2113
2121
|
*/
|
|
2114
|
-
custom?: { [key:string]: any };
|
|
2122
|
+
custom?: { [key: string]: any };
|
|
2115
2123
|
/**
|
|
2116
2124
|
*
|
|
2117
2125
|
* @type {number}
|
|
@@ -2156,7 +2164,6 @@ export interface CollectUserFeedbackResponse {
|
|
|
2156
2164
|
*/
|
|
2157
2165
|
duration: string;
|
|
2158
2166
|
}
|
|
2159
|
-
|
|
2160
2167
|
/**
|
|
2161
2168
|
*
|
|
2162
2169
|
* @export
|
|
@@ -2275,7 +2282,6 @@ export interface Coordinates {
|
|
|
2275
2282
|
*/
|
|
2276
2283
|
longitude: number;
|
|
2277
2284
|
}
|
|
2278
|
-
|
|
2279
2285
|
/**
|
|
2280
2286
|
*
|
|
2281
2287
|
* @export
|
|
@@ -2636,7 +2642,6 @@ export interface GeofenceSettingsRequest {
|
|
|
2636
2642
|
*/
|
|
2637
2643
|
names?: Array<string>;
|
|
2638
2644
|
}
|
|
2639
|
-
|
|
2640
2645
|
/**
|
|
2641
2646
|
*
|
|
2642
2647
|
* @export
|
|
@@ -2680,7 +2685,6 @@ export interface GeolocationResult {
|
|
|
2680
2685
|
*/
|
|
2681
2686
|
subdivision_iso_code: string;
|
|
2682
2687
|
}
|
|
2683
|
-
|
|
2684
2688
|
/**
|
|
2685
2689
|
*
|
|
2686
2690
|
* @export
|
|
@@ -2803,7 +2807,6 @@ export interface GetCallStatsResponse {
|
|
|
2803
2807
|
*/
|
|
2804
2808
|
sfus: Array<SFULocationResponse>;
|
|
2805
2809
|
}
|
|
2806
|
-
|
|
2807
2810
|
/**
|
|
2808
2811
|
*
|
|
2809
2812
|
* @export
|
|
@@ -2953,7 +2956,6 @@ export interface GoLiveResponse {
|
|
|
2953
2956
|
*/
|
|
2954
2957
|
duration: string;
|
|
2955
2958
|
}
|
|
2956
|
-
|
|
2957
2959
|
// Manually added because API spec is faulty
|
|
2958
2960
|
/**
|
|
2959
2961
|
*
|
|
@@ -2980,7 +2982,6 @@ export interface HealthCheckEvent {
|
|
|
2980
2982
|
*/
|
|
2981
2983
|
type: string;
|
|
2982
2984
|
}
|
|
2983
|
-
|
|
2984
2985
|
/**
|
|
2985
2986
|
*
|
|
2986
2987
|
* @export
|
|
@@ -3372,6 +3373,55 @@ export interface MuteUsersResponse {
|
|
|
3372
3373
|
*/
|
|
3373
3374
|
duration: string;
|
|
3374
3375
|
}
|
|
3376
|
+
/**
|
|
3377
|
+
*
|
|
3378
|
+
* @export
|
|
3379
|
+
* @interface NoiseCancellationSettings
|
|
3380
|
+
*/
|
|
3381
|
+
export interface NoiseCancellationSettings {
|
|
3382
|
+
/**
|
|
3383
|
+
*
|
|
3384
|
+
* @type {string}
|
|
3385
|
+
* @memberof NoiseCancellationSettings
|
|
3386
|
+
*/
|
|
3387
|
+
mode: NoiseCancellationSettingsModeEnum;
|
|
3388
|
+
}
|
|
3389
|
+
|
|
3390
|
+
/**
|
|
3391
|
+
* @export
|
|
3392
|
+
*/
|
|
3393
|
+
export const NoiseCancellationSettingsModeEnum = {
|
|
3394
|
+
AVAILABLE: 'available',
|
|
3395
|
+
DISABLED: 'disabled',
|
|
3396
|
+
AUTO_ON: 'auto-on',
|
|
3397
|
+
} as const;
|
|
3398
|
+
export type NoiseCancellationSettingsModeEnum =
|
|
3399
|
+
(typeof NoiseCancellationSettingsModeEnum)[keyof typeof NoiseCancellationSettingsModeEnum];
|
|
3400
|
+
|
|
3401
|
+
/**
|
|
3402
|
+
*
|
|
3403
|
+
* @export
|
|
3404
|
+
* @interface NoiseCancellationSettingsRequest
|
|
3405
|
+
*/
|
|
3406
|
+
export interface NoiseCancellationSettingsRequest {
|
|
3407
|
+
/**
|
|
3408
|
+
*
|
|
3409
|
+
* @type {string}
|
|
3410
|
+
* @memberof NoiseCancellationSettingsRequest
|
|
3411
|
+
*/
|
|
3412
|
+
mode?: NoiseCancellationSettingsRequestModeEnum;
|
|
3413
|
+
}
|
|
3414
|
+
|
|
3415
|
+
/**
|
|
3416
|
+
* @export
|
|
3417
|
+
*/
|
|
3418
|
+
export const NoiseCancellationSettingsRequestModeEnum = {
|
|
3419
|
+
AVAILABLE: 'available',
|
|
3420
|
+
DISABLED: 'disabled',
|
|
3421
|
+
AUTO_ON: 'auto-on',
|
|
3422
|
+
} as const;
|
|
3423
|
+
export type NoiseCancellationSettingsRequestModeEnum =
|
|
3424
|
+
(typeof NoiseCancellationSettingsRequestModeEnum)[keyof typeof NoiseCancellationSettingsRequestModeEnum];
|
|
3375
3425
|
|
|
3376
3426
|
/**
|
|
3377
3427
|
* All possibility of string to use
|
|
@@ -3381,6 +3431,7 @@ export const OwnCapability = {
|
|
|
3381
3431
|
BLOCK_USERS: 'block-users',
|
|
3382
3432
|
CREATE_CALL: 'create-call',
|
|
3383
3433
|
CREATE_REACTION: 'create-reaction',
|
|
3434
|
+
ENABLE_NOISE_CANCELLATION: 'enable-noise-cancellation',
|
|
3384
3435
|
END_CALL: 'end-call',
|
|
3385
3436
|
JOIN_BACKSTAGE: 'join-backstage',
|
|
3386
3437
|
JOIN_CALL: 'join-call',
|
|
@@ -4349,7 +4400,6 @@ export interface Subsession {
|
|
|
4349
4400
|
*/
|
|
4350
4401
|
sfu_id: string;
|
|
4351
4402
|
}
|
|
4352
|
-
|
|
4353
4403
|
/**
|
|
4354
4404
|
*
|
|
4355
4405
|
* @export
|
|
@@ -4913,7 +4963,6 @@ export interface UserResponse {
|
|
|
4913
4963
|
*/
|
|
4914
4964
|
updated_at: string;
|
|
4915
4965
|
}
|
|
4916
|
-
|
|
4917
4966
|
/**
|
|
4918
4967
|
*
|
|
4919
4968
|
* @export
|
|
@@ -5132,6 +5181,44 @@ export interface UserStats {
|
|
|
5132
5181
|
*/
|
|
5133
5182
|
session_stats: Array<UserSessionStats>;
|
|
5134
5183
|
}
|
|
5184
|
+
/**
|
|
5185
|
+
*
|
|
5186
|
+
* @export
|
|
5187
|
+
* @interface VideoQuality
|
|
5188
|
+
*/
|
|
5189
|
+
export interface VideoQuality {
|
|
5190
|
+
/**
|
|
5191
|
+
*
|
|
5192
|
+
* @type {VideoResolution}
|
|
5193
|
+
* @memberof VideoQuality
|
|
5194
|
+
*/
|
|
5195
|
+
resolution?: VideoResolution;
|
|
5196
|
+
/**
|
|
5197
|
+
*
|
|
5198
|
+
* @type {string}
|
|
5199
|
+
* @memberof VideoQuality
|
|
5200
|
+
*/
|
|
5201
|
+
usage_type?: string;
|
|
5202
|
+
}
|
|
5203
|
+
/**
|
|
5204
|
+
*
|
|
5205
|
+
* @export
|
|
5206
|
+
* @interface VideoResolution
|
|
5207
|
+
*/
|
|
5208
|
+
export interface VideoResolution {
|
|
5209
|
+
/**
|
|
5210
|
+
*
|
|
5211
|
+
* @type {number}
|
|
5212
|
+
* @memberof VideoResolution
|
|
5213
|
+
*/
|
|
5214
|
+
height: number;
|
|
5215
|
+
/**
|
|
5216
|
+
*
|
|
5217
|
+
* @type {number}
|
|
5218
|
+
* @memberof VideoResolution
|
|
5219
|
+
*/
|
|
5220
|
+
width: number;
|
|
5221
|
+
}
|
|
5135
5222
|
/**
|
|
5136
5223
|
*
|
|
5137
5224
|
* @export
|
|
@@ -5230,40 +5317,6 @@ export const VideoSettingsRequestCameraFacingEnum = {
|
|
|
5230
5317
|
export type VideoSettingsRequestCameraFacingEnum =
|
|
5231
5318
|
(typeof VideoSettingsRequestCameraFacingEnum)[keyof typeof VideoSettingsRequestCameraFacingEnum];
|
|
5232
5319
|
|
|
5233
|
-
/**
|
|
5234
|
-
*
|
|
5235
|
-
* @export
|
|
5236
|
-
* @interface VideoQuality
|
|
5237
|
-
*/
|
|
5238
|
-
export interface VideoQuality {
|
|
5239
|
-
/**
|
|
5240
|
-
*
|
|
5241
|
-
* @type {VideoResolution}
|
|
5242
|
-
* @memberof VideoQuality
|
|
5243
|
-
*/
|
|
5244
|
-
resolution: VideoResolution;
|
|
5245
|
-
}
|
|
5246
|
-
|
|
5247
|
-
/**
|
|
5248
|
-
*
|
|
5249
|
-
* @export
|
|
5250
|
-
* @interface VideoResolution
|
|
5251
|
-
*/
|
|
5252
|
-
export interface VideoResolution {
|
|
5253
|
-
/**
|
|
5254
|
-
*
|
|
5255
|
-
* @type {number}
|
|
5256
|
-
* @memberof VideoResolution
|
|
5257
|
-
*/
|
|
5258
|
-
height: number;
|
|
5259
|
-
/**
|
|
5260
|
-
*
|
|
5261
|
-
* @type {number}
|
|
5262
|
-
* @memberof VideoResolution
|
|
5263
|
-
*/
|
|
5264
|
-
width: number;
|
|
5265
|
-
}
|
|
5266
|
-
|
|
5267
5320
|
/**
|
|
5268
5321
|
*
|
|
5269
5322
|
* @export
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// @generated by protobuf-ts 2.9.
|
|
2
|
+
// @generated by protobuf-ts 2.9.4 with parameter long_type_string,client_generic,server_none,eslint_disable
|
|
3
3
|
// @generated from protobuf file "google/protobuf/struct.proto" (package "google.protobuf", syntax proto3)
|
|
4
4
|
// tslint:disable
|
|
5
5
|
//
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// @generated by protobuf-ts 2.9.
|
|
2
|
+
// @generated by protobuf-ts 2.9.4 with parameter long_type_string,client_generic,server_none,eslint_disable
|
|
3
3
|
// @generated from protobuf file "google/protobuf/timestamp.proto" (package "google.protobuf", syntax proto3)
|
|
4
4
|
// tslint:disable
|
|
5
5
|
//
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// @generated by protobuf-ts 2.9.
|
|
2
|
+
// @generated by protobuf-ts 2.9.4 with parameter long_type_string,client_generic,server_none,eslint_disable
|
|
3
3
|
// @generated from protobuf file "video/sfu/event/events.proto" (package "stream.video.sfu.event", syntax proto3)
|
|
4
4
|
// tslint:disable
|
|
5
5
|
import type {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// @generated by protobuf-ts 2.9.
|
|
2
|
+
// @generated by protobuf-ts 2.9.4 with parameter long_type_string,client_generic,server_none,eslint_disable
|
|
3
3
|
// @generated from protobuf file "video/sfu/models/models.proto" (package "stream.video.sfu.models", syntax proto3)
|
|
4
4
|
// tslint:disable
|
|
5
5
|
import type {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
// @generated by protobuf-ts 2.9.
|
|
2
|
+
// @generated by protobuf-ts 2.9.4 with parameter long_type_string,client_generic,server_none,eslint_disable
|
|
3
3
|
// @generated from protobuf file "video/sfu/signal_rpc/signal.proto" (package "stream.video.sfu.signal", syntax proto3)
|
|
4
4
|
// tslint:disable
|
|
5
5
|
import type {
|
|
@@ -19,6 +19,10 @@ import type {
|
|
|
19
19
|
SendStatsResponse,
|
|
20
20
|
SetPublisherRequest,
|
|
21
21
|
SetPublisherResponse,
|
|
22
|
+
StartNoiseCancellationRequest,
|
|
23
|
+
StartNoiseCancellationResponse,
|
|
24
|
+
StopNoiseCancellationRequest,
|
|
25
|
+
StopNoiseCancellationResponse,
|
|
22
26
|
UpdateMuteStatesRequest,
|
|
23
27
|
UpdateMuteStatesResponse,
|
|
24
28
|
UpdateSubscriptionsRequest,
|
|
@@ -89,6 +93,20 @@ export interface ISignalServerClient {
|
|
|
89
93
|
input: SendStatsRequest,
|
|
90
94
|
options?: RpcOptions,
|
|
91
95
|
): UnaryCall<SendStatsRequest, SendStatsResponse>;
|
|
96
|
+
/**
|
|
97
|
+
* @generated from protobuf rpc: StartNoiseCancellation(stream.video.sfu.signal.StartNoiseCancellationRequest) returns (stream.video.sfu.signal.StartNoiseCancellationResponse);
|
|
98
|
+
*/
|
|
99
|
+
startNoiseCancellation(
|
|
100
|
+
input: StartNoiseCancellationRequest,
|
|
101
|
+
options?: RpcOptions,
|
|
102
|
+
): UnaryCall<StartNoiseCancellationRequest, StartNoiseCancellationResponse>;
|
|
103
|
+
/**
|
|
104
|
+
* @generated from protobuf rpc: StopNoiseCancellation(stream.video.sfu.signal.StopNoiseCancellationRequest) returns (stream.video.sfu.signal.StopNoiseCancellationResponse);
|
|
105
|
+
*/
|
|
106
|
+
stopNoiseCancellation(
|
|
107
|
+
input: StopNoiseCancellationRequest,
|
|
108
|
+
options?: RpcOptions,
|
|
109
|
+
): UnaryCall<StopNoiseCancellationRequest, StopNoiseCancellationResponse>;
|
|
92
110
|
}
|
|
93
111
|
/**
|
|
94
112
|
* @generated from protobuf service stream.video.sfu.signal.SignalServer
|
|
@@ -223,4 +241,32 @@ export class SignalServerClient implements ISignalServerClient, ServiceInfo {
|
|
|
223
241
|
input,
|
|
224
242
|
);
|
|
225
243
|
}
|
|
244
|
+
/**
|
|
245
|
+
* @generated from protobuf rpc: StartNoiseCancellation(stream.video.sfu.signal.StartNoiseCancellationRequest) returns (stream.video.sfu.signal.StartNoiseCancellationResponse);
|
|
246
|
+
*/
|
|
247
|
+
startNoiseCancellation(
|
|
248
|
+
input: StartNoiseCancellationRequest,
|
|
249
|
+
options?: RpcOptions,
|
|
250
|
+
): UnaryCall<StartNoiseCancellationRequest, StartNoiseCancellationResponse> {
|
|
251
|
+
const method = this.methods[7],
|
|
252
|
+
opt = this._transport.mergeOptions(options);
|
|
253
|
+
return stackIntercept<
|
|
254
|
+
StartNoiseCancellationRequest,
|
|
255
|
+
StartNoiseCancellationResponse
|
|
256
|
+
>('unary', this._transport, method, opt, input);
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* @generated from protobuf rpc: StopNoiseCancellation(stream.video.sfu.signal.StopNoiseCancellationRequest) returns (stream.video.sfu.signal.StopNoiseCancellationResponse);
|
|
260
|
+
*/
|
|
261
|
+
stopNoiseCancellation(
|
|
262
|
+
input: StopNoiseCancellationRequest,
|
|
263
|
+
options?: RpcOptions,
|
|
264
|
+
): UnaryCall<StopNoiseCancellationRequest, StopNoiseCancellationResponse> {
|
|
265
|
+
const method = this.methods[8],
|
|
266
|
+
opt = this._transport.mergeOptions(options);
|
|
267
|
+
return stackIntercept<
|
|
268
|
+
StopNoiseCancellationRequest,
|
|
269
|
+
StopNoiseCancellationResponse
|
|
270
|
+
>('unary', this._transport, method, opt, input);
|
|
271
|
+
}
|
|
226
272
|
}
|