livekit-client 1.9.2 → 1.9.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (111) hide show
  1. package/README.md +2 -0
  2. package/dist/livekit-client.esm.mjs +8251 -8123
  3. package/dist/livekit-client.esm.mjs.map +1 -1
  4. package/dist/livekit-client.umd.js +1 -1
  5. package/dist/livekit-client.umd.js.map +1 -1
  6. package/dist/src/AsyncQueue.d.ts +23 -0
  7. package/dist/src/AsyncQueue.d.ts.map +1 -0
  8. package/dist/src/api/SignalClient.d.ts +98 -98
  9. package/dist/src/api/SignalClient.d.ts.map +1 -1
  10. package/dist/src/connectionHelper/ConnectionCheck.d.ts +25 -24
  11. package/dist/src/connectionHelper/ConnectionCheck.d.ts.map +1 -1
  12. package/dist/src/connectionHelper/checks/Checker.d.ts +58 -58
  13. package/dist/src/connectionHelper/checks/publishAudio.d.ts +5 -5
  14. package/dist/src/connectionHelper/checks/publishVideo.d.ts +5 -5
  15. package/dist/src/connectionHelper/checks/reconnect.d.ts +5 -5
  16. package/dist/src/connectionHelper/checks/turn.d.ts +5 -5
  17. package/dist/src/connectionHelper/checks/webrtc.d.ts +5 -5
  18. package/dist/src/connectionHelper/checks/websocket.d.ts +5 -5
  19. package/dist/src/index.d.ts +34 -31
  20. package/dist/src/index.d.ts.map +1 -1
  21. package/dist/src/logger.d.ts +25 -25
  22. package/dist/src/options.d.ts +98 -98
  23. package/dist/src/proto/google/protobuf/timestamp.d.ts +145 -145
  24. package/dist/src/proto/livekit_models.d.ts +2300 -2300
  25. package/dist/src/proto/livekit_rtc.d.ts +14032 -14032
  26. package/dist/src/room/DefaultReconnectPolicy.d.ts +7 -7
  27. package/dist/src/room/DeviceManager.d.ts +8 -8
  28. package/dist/src/room/PCTransport.d.ts +36 -37
  29. package/dist/src/room/PCTransport.d.ts.map +1 -1
  30. package/dist/src/room/RTCEngine.d.ts +126 -121
  31. package/dist/src/room/RTCEngine.d.ts.map +1 -1
  32. package/dist/src/room/ReconnectPolicy.d.ts +23 -23
  33. package/dist/src/room/RegionUrlProvider.d.ts +13 -13
  34. package/dist/src/room/Room.d.ts +232 -232
  35. package/dist/src/room/defaults.d.ts +7 -7
  36. package/dist/src/room/defaults.d.ts.map +1 -1
  37. package/dist/src/room/errors.d.ts +42 -42
  38. package/dist/src/room/events.d.ts +455 -455
  39. package/dist/src/room/participant/LocalParticipant.d.ts +170 -170
  40. package/dist/src/room/participant/LocalParticipant.d.ts.map +1 -1
  41. package/dist/src/room/participant/Participant.d.ts +93 -93
  42. package/dist/src/room/participant/ParticipantTrackPermission.d.ts +25 -25
  43. package/dist/src/room/participant/RemoteParticipant.d.ts +52 -51
  44. package/dist/src/room/participant/RemoteParticipant.d.ts.map +1 -1
  45. package/dist/src/room/participant/publishUtils.d.ts +19 -18
  46. package/dist/src/room/participant/publishUtils.d.ts.map +1 -1
  47. package/dist/src/room/stats.d.ts +66 -66
  48. package/dist/src/room/timers.d.ts +11 -12
  49. package/dist/src/room/timers.d.ts.map +1 -1
  50. package/dist/src/room/track/LocalAudioTrack.d.ts +24 -24
  51. package/dist/src/room/track/LocalAudioTrack.d.ts.map +1 -1
  52. package/dist/src/room/track/LocalTrack.d.ts +43 -43
  53. package/dist/src/room/track/LocalTrackPublication.d.ts +37 -37
  54. package/dist/src/room/track/LocalVideoTrack.d.ts +53 -53
  55. package/dist/src/room/track/LocalVideoTrack.d.ts.map +1 -1
  56. package/dist/src/room/track/RemoteAudioTrack.d.ts +52 -52
  57. package/dist/src/room/track/RemoteAudioTrack.d.ts.map +1 -1
  58. package/dist/src/room/track/RemoteTrack.d.ts +14 -14
  59. package/dist/src/room/track/RemoteTrackPublication.d.ts +60 -60
  60. package/dist/src/room/track/RemoteVideoTrack.d.ts +52 -52
  61. package/dist/src/room/track/RemoteVideoTrack.d.ts.map +1 -1
  62. package/dist/src/room/track/Track.d.ts +124 -124
  63. package/dist/src/room/track/TrackPublication.d.ts +67 -67
  64. package/dist/src/room/track/create.d.ts +23 -23
  65. package/dist/src/room/track/create.d.ts.map +1 -1
  66. package/dist/src/room/track/options.d.ts +255 -247
  67. package/dist/src/room/track/options.d.ts.map +1 -1
  68. package/dist/src/room/track/types.d.ts +22 -22
  69. package/dist/src/room/track/utils.d.ts +13 -13
  70. package/dist/src/room/types.d.ts +25 -25
  71. package/dist/src/room/utils.d.ts +86 -85
  72. package/dist/src/room/utils.d.ts.map +1 -1
  73. package/dist/src/test/MockMediaStreamTrack.d.ts +25 -25
  74. package/dist/src/test/mocks.d.ts +10 -10
  75. package/dist/src/version.d.ts +2 -2
  76. package/dist/ts4.2/src/AsyncQueue.d.ts +23 -0
  77. package/dist/ts4.2/src/api/SignalClient.d.ts +2 -2
  78. package/dist/ts4.2/src/connectionHelper/ConnectionCheck.d.ts +2 -1
  79. package/dist/ts4.2/src/index.d.ts +8 -6
  80. package/dist/ts4.2/src/room/PCTransport.d.ts +2 -3
  81. package/dist/ts4.2/src/room/RTCEngine.d.ts +6 -1
  82. package/dist/ts4.2/src/room/defaults.d.ts +1 -1
  83. package/dist/ts4.2/src/room/participant/LocalParticipant.d.ts +4 -4
  84. package/dist/ts4.2/src/room/participant/RemoteParticipant.d.ts +2 -1
  85. package/dist/ts4.2/src/room/participant/publishUtils.d.ts +2 -1
  86. package/dist/ts4.2/src/room/timers.d.ts +4 -5
  87. package/dist/ts4.2/src/room/track/LocalAudioTrack.d.ts +1 -1
  88. package/dist/ts4.2/src/room/track/LocalVideoTrack.d.ts +1 -1
  89. package/dist/ts4.2/src/room/track/RemoteAudioTrack.d.ts +1 -1
  90. package/dist/ts4.2/src/room/track/create.d.ts +1 -1
  91. package/dist/ts4.2/src/room/track/options.d.ts +10 -2
  92. package/dist/ts4.2/src/room/utils.d.ts +1 -0
  93. package/package.json +18 -31
  94. package/src/AsyncQueue.test.ts +99 -0
  95. package/src/AsyncQueue.ts +57 -0
  96. package/src/api/SignalClient.ts +14 -15
  97. package/src/connectionHelper/ConnectionCheck.ts +3 -2
  98. package/src/index.ts +13 -8
  99. package/src/room/PCTransport.ts +10 -6
  100. package/src/room/RTCEngine.ts +10 -3
  101. package/src/room/defaults.ts +6 -4
  102. package/src/room/participant/LocalParticipant.ts +10 -9
  103. package/src/room/participant/RemoteParticipant.ts +2 -1
  104. package/src/room/participant/publishUtils.ts +7 -5
  105. package/src/room/track/LocalAudioTrack.ts +2 -1
  106. package/src/room/track/LocalVideoTrack.ts +3 -2
  107. package/src/room/track/RemoteAudioTrack.ts +2 -1
  108. package/src/room/track/RemoteVideoTrack.ts +4 -8
  109. package/src/room/track/create.ts +2 -2
  110. package/src/room/track/options.ts +23 -7
  111. package/src/room/utils.ts +15 -2
@@ -1,52 +1,53 @@
1
- import type { SignalClient } from '../../api/SignalClient';
2
- import type { ParticipantInfo } from '../../proto/livekit_models';
3
- import RemoteTrackPublication from '../track/RemoteTrackPublication';
4
- import { Track } from '../track/Track';
5
- import type { AudioOutputOptions } from '../track/options';
6
- import type { AdaptiveStreamSettings } from '../track/types';
7
- import Participant, { ParticipantEventCallbacks } from './Participant';
8
- export default class RemoteParticipant extends Participant {
9
- audioTracks: Map<string, RemoteTrackPublication>;
10
- videoTracks: Map<string, RemoteTrackPublication>;
11
- tracks: Map<string, RemoteTrackPublication>;
12
- signalClient: SignalClient;
13
- private volume?;
14
- private audioContext?;
15
- private audioOutput?;
16
- /** @internal */
17
- static fromParticipantInfo(signalClient: SignalClient, pi: ParticipantInfo): RemoteParticipant;
18
- /** @internal */
19
- constructor(signalClient: SignalClient, sid: string, identity?: string, name?: string, metadata?: string);
20
- protected addTrackPublication(publication: RemoteTrackPublication): void;
21
- getTrack(source: Track.Source): RemoteTrackPublication | undefined;
22
- getTrackByName(name: string): RemoteTrackPublication | undefined;
23
- /**
24
- * sets the volume on the participant's microphone track
25
- * if no track exists the volume will be applied when the microphone track is added
26
- */
27
- setVolume(volume: number): void;
28
- /**
29
- * gets the volume on the participant's microphone track
30
- */
31
- getVolume(): number | undefined;
32
- /** @internal */
33
- addSubscribedMediaTrack(mediaTrack: MediaStreamTrack, sid: Track.SID, mediaStream: MediaStream, receiver?: RTCRtpReceiver, adaptiveStreamSettings?: AdaptiveStreamSettings, triesLeft?: number): RemoteTrackPublication | undefined;
34
- /** @internal */
35
- get hasMetadata(): boolean;
36
- getTrackPublication(sid: Track.SID): RemoteTrackPublication | undefined;
37
- /** @internal */
38
- updateInfo(info: ParticipantInfo): boolean;
39
- /** @internal */
40
- unpublishTrack(sid: Track.SID, sendUnpublish?: boolean): void;
41
- /**
42
- * @internal
43
- */
44
- setAudioContext(ctx: AudioContext | undefined): void;
45
- /**
46
- * @internal
47
- */
48
- setAudioOutput(output: AudioOutputOptions): Promise<void>;
49
- /** @internal */
50
- emit<E extends keyof ParticipantEventCallbacks>(event: E, ...args: Parameters<ParticipantEventCallbacks[E]>): boolean;
51
- }
1
+ import type { SignalClient } from '../../api/SignalClient';
2
+ import type { ParticipantInfo } from '../../proto/livekit_models';
3
+ import RemoteTrackPublication from '../track/RemoteTrackPublication';
4
+ import { Track } from '../track/Track';
5
+ import type { AudioOutputOptions } from '../track/options';
6
+ import type { AdaptiveStreamSettings } from '../track/types';
7
+ import Participant from './Participant';
8
+ import type { ParticipantEventCallbacks } from './Participant';
9
+ export default class RemoteParticipant extends Participant {
10
+ audioTracks: Map<string, RemoteTrackPublication>;
11
+ videoTracks: Map<string, RemoteTrackPublication>;
12
+ tracks: Map<string, RemoteTrackPublication>;
13
+ signalClient: SignalClient;
14
+ private volume?;
15
+ private audioContext?;
16
+ private audioOutput?;
17
+ /** @internal */
18
+ static fromParticipantInfo(signalClient: SignalClient, pi: ParticipantInfo): RemoteParticipant;
19
+ /** @internal */
20
+ constructor(signalClient: SignalClient, sid: string, identity?: string, name?: string, metadata?: string);
21
+ protected addTrackPublication(publication: RemoteTrackPublication): void;
22
+ getTrack(source: Track.Source): RemoteTrackPublication | undefined;
23
+ getTrackByName(name: string): RemoteTrackPublication | undefined;
24
+ /**
25
+ * sets the volume on the participant's microphone track
26
+ * if no track exists the volume will be applied when the microphone track is added
27
+ */
28
+ setVolume(volume: number): void;
29
+ /**
30
+ * gets the volume on the participant's microphone track
31
+ */
32
+ getVolume(): number | undefined;
33
+ /** @internal */
34
+ addSubscribedMediaTrack(mediaTrack: MediaStreamTrack, sid: Track.SID, mediaStream: MediaStream, receiver?: RTCRtpReceiver, adaptiveStreamSettings?: AdaptiveStreamSettings, triesLeft?: number): RemoteTrackPublication | undefined;
35
+ /** @internal */
36
+ get hasMetadata(): boolean;
37
+ getTrackPublication(sid: Track.SID): RemoteTrackPublication | undefined;
38
+ /** @internal */
39
+ updateInfo(info: ParticipantInfo): boolean;
40
+ /** @internal */
41
+ unpublishTrack(sid: Track.SID, sendUnpublish?: boolean): void;
42
+ /**
43
+ * @internal
44
+ */
45
+ setAudioContext(ctx: AudioContext | undefined): void;
46
+ /**
47
+ * @internal
48
+ */
49
+ setAudioOutput(output: AudioOutputOptions): Promise<void>;
50
+ /** @internal */
51
+ emit<E extends keyof ParticipantEventCallbacks>(event: E, ...args: Parameters<ParticipantEventCallbacks[E]>): boolean;
52
+ }
52
53
  //# sourceMappingURL=RemoteParticipant.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RemoteParticipant.d.ts","sourceRoot":"","sources":["../../../../src/room/participant/RemoteParticipant.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAE3D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAKlE,OAAO,sBAAsB,MAAM,iCAAiC,CAAC;AAErE,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAEvC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAC3D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AAC7D,OAAO,WAAW,EAAE,EAAE,yBAAyB,EAAE,MAAM,eAAe,CAAC;AAEvE,MAAM,CAAC,OAAO,OAAO,iBAAkB,SAAQ,WAAW;IACxD,WAAW,EAAE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gB;IAChB,IAAI,CAAC,CAAC,SAAS,MAAM,yBAAyB,EAC5C,KAAK,EAAE,CAAC,EACR,GAAG,IAAI,EAAE,UAAU,CAAC,yBAAyB,CAAC,CAAC,CAAC,CAAC,GAChD,OAAO;CAIX"}
@@ -1,19 +1,20 @@
1
- import LocalAudioTrack from '../track/LocalAudioTrack';
2
- import LocalVideoTrack from '../track/LocalVideoTrack';
3
- import { BackupVideoCodec, TrackPublishOptions, VideoCodec, VideoEncoding, VideoPreset } from '../track/options';
4
- /** @internal */
5
- export declare function mediaTrackToLocalTrack(mediaStreamTrack: MediaStreamTrack, constraints?: MediaTrackConstraints): LocalVideoTrack | LocalAudioTrack;
6
- export declare const presets169: VideoPreset[];
7
- export declare const presets43: VideoPreset[];
8
- export declare const presetsScreenShare: VideoPreset[];
9
- export declare const defaultSimulcastPresets169: VideoPreset[];
10
- export declare const defaultSimulcastPresets43: VideoPreset[];
11
- export declare const computeDefaultScreenShareSimulcastPresets: (fromPreset: VideoPreset) => VideoPreset[];
12
- export declare function computeVideoEncodings(isScreenShare: boolean, width?: number, height?: number, options?: TrackPublishOptions): RTCRtpEncodingParameters[];
13
- export declare function computeTrackBackupEncodings(track: LocalVideoTrack, videoCodec: BackupVideoCodec, opts: TrackPublishOptions): RTCRtpEncodingParameters[] | undefined;
14
- export declare function determineAppropriateEncoding(isScreenShare: boolean, width: number, height: number, codec?: VideoCodec): VideoEncoding;
15
- export declare function presetsForResolution(isScreenShare: boolean, width: number, height: number): VideoPreset[];
16
- export declare function defaultSimulcastLayers(isScreenShare: boolean, original: VideoPreset): VideoPreset[];
17
- /** @internal */
18
- export declare function sortPresets(presets: Array<VideoPreset> | undefined): VideoPreset[] | undefined;
1
+ import LocalAudioTrack from '../track/LocalAudioTrack';
2
+ import LocalVideoTrack from '../track/LocalVideoTrack';
3
+ import { VideoPreset } from '../track/options';
4
+ import type { BackupVideoCodec, TrackPublishOptions, VideoCodec, VideoEncoding } from '../track/options';
5
+ /** @internal */
6
+ export declare function mediaTrackToLocalTrack(mediaStreamTrack: MediaStreamTrack, constraints?: MediaTrackConstraints): LocalVideoTrack | LocalAudioTrack;
7
+ export declare const presets169: VideoPreset[];
8
+ export declare const presets43: VideoPreset[];
9
+ export declare const presetsScreenShare: VideoPreset[];
10
+ export declare const defaultSimulcastPresets169: VideoPreset[];
11
+ export declare const defaultSimulcastPresets43: VideoPreset[];
12
+ export declare const computeDefaultScreenShareSimulcastPresets: (fromPreset: VideoPreset) => VideoPreset[];
13
+ export declare function computeVideoEncodings(isScreenShare: boolean, width?: number, height?: number, options?: TrackPublishOptions): RTCRtpEncodingParameters[];
14
+ export declare function computeTrackBackupEncodings(track: LocalVideoTrack, videoCodec: BackupVideoCodec, opts: TrackPublishOptions): RTCRtpEncodingParameters[] | undefined;
15
+ export declare function determineAppropriateEncoding(isScreenShare: boolean, width: number, height: number, codec?: VideoCodec): VideoEncoding;
16
+ export declare function presetsForResolution(isScreenShare: boolean, width: number, height: number): VideoPreset[];
17
+ export declare function defaultSimulcastLayers(isScreenShare: boolean, original: VideoPreset): VideoPreset[];
18
+ /** @internal */
19
+ export declare function sortPresets(presets: Array<VideoPreset> | undefined): VideoPreset[] | undefined;
19
20
  //# sourceMappingURL=publishUtils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"publishUtils.d.ts","sourceRoot":"","sources":["../../../../src/room/participant/publishUtils.ts"],"names":[],"mappings":"AAEA,OAAO,eAAe,MAAM,0BAA0B,CAAC;AACvD,OAAO,eAAe,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EACL,gBAAgB,EAEhB,mBAAmB,EACnB,UAAU,EACV,aAAa,EACb,WAAW,EAGZ,MAAM,kBAAkB,CAAC;AAG1B,gBAAgB;AAChB,wBAAgB,sBAAsB,CACpC,gBAAgB,EAAE,gBAAgB,EAClC,WAAW,CAAC,EAAE,qBAAqB,GAClC,eAAe,GAAG,eAAe,CASnC;AAGD,eAAO,MAAM,UAAU,eAA8B,CAAC;AAGtD,eAAO,MAAM,SAAS,eAAgC,CAAC;AAGvD,eAAO,MAAM,kBAAkB,eAAoC,CAAC;AAGpE,eAAO,MAAM,0BAA0B,eAAyC,CAAC;AAGjF,eAAO,MAAM,yBAAyB,eAA6C,CAAC;AAGpF,eAAO,MAAM,yCAAyC,eAAgB,WAAW,kBAiBhF,CAAC;AAwBF,wBAAgB,qBAAqB,CACnC,aAAa,EAAE,OAAO,EACtB,KAAK,CAAC,EAAE,MAAM,EACd,MAAM,CAAC,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,mBAAmB,GAC5B,wBAAwB,EAAE,CAgG5B;AAED,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,eAAe,EACtB,UAAU,EAAE,gBAAgB,EAC5B,IAAI,EAAE,mBAAmB,0CA4B1B;AAGD,wBAAgB,4BAA4B,CAC1C,aAAa,EAAE,OAAO,EACtB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,KAAK,CAAC,EAAE,UAAU,GACjB,aAAa,CAiCf;AAGD,wBAAgB,oBAAoB,CAClC,aAAa,EAAE,OAAO,EACtB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,GACb,WAAW,EAAE,CASf;AAGD,wBAAgB,sBAAsB,CACpC,aAAa,EAAE,OAAO,EACtB,QAAQ,EAAE,WAAW,GACpB,WAAW,EAAE,CAUf;AA4BD,gBAAgB;AAChB,wBAAgB,WAAW,CAAC,OAAO,EAAE,KAAK,CAAC,WAAW,CAAC,GAAG,SAAS,6BAelE"}
1
+ {"version":3,"file":"publishUtils.d.ts","sourceRoot":"","sources":["../../../../src/room/participant/publishUtils.ts"],"names":[],"mappings":"AAEA,OAAO,eAAe,MAAM,0BAA0B,CAAC;AACvD,OAAO,eAAe,MAAM,0BAA0B,CAAC;AAEvD,OAAO,EAAsB,WAAW,EAAgC,MAAM,kBAAkB,CAAC;AACjG,OAAO,KAAK,EACV,gBAAgB,EAChB,mBAAmB,EACnB,UAAU,EACV,aAAa,EACd,MAAM,kBAAkB,CAAC;AAG1B,gBAAgB;AAChB,wBAAgB,sBAAsB,CACpC,gBAAgB,EAAE,gBAAgB,EAClC,WAAW,CAAC,EAAE,qBAAqB,GAClC,eAAe,GAAG,eAAe,CASnC;AAGD,eAAO,MAAM,UAAU,eAA8B,CAAC;AAGtD,eAAO,MAAM,SAAS,eAAgC,CAAC;AAGvD,eAAO,MAAM,kBAAkB,eAAoC,CAAC;AAGpE,eAAO,MAAM,0BAA0B,eAAyC,CAAC;AAGjF,eAAO,MAAM,yBAAyB,eAA6C,CAAC;AAGpF,eAAO,MAAM,yCAAyC,eAAgB,WAAW,kBAkBhF,CAAC;AAwBF,wBAAgB,qBAAqB,CACnC,aAAa,EAAE,OAAO,EACtB,KAAK,CAAC,EAAE,MAAM,EACd,MAAM,CAAC,EAAE,MAAM,EACf,OAAO,CAAC,EAAE,mBAAmB,GAC5B,wBAAwB,EAAE,CAgG5B;AAED,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,eAAe,EACtB,UAAU,EAAE,gBAAgB,EAC5B,IAAI,EAAE,mBAAmB,0CA4B1B;AAGD,wBAAgB,4BAA4B,CAC1C,aAAa,EAAE,OAAO,EACtB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,KAAK,CAAC,EAAE,UAAU,GACjB,aAAa,CAiCf;AAGD,wBAAgB,oBAAoB,CAClC,aAAa,EAAE,OAAO,EACtB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,GACb,WAAW,EAAE,CASf;AAGD,wBAAgB,sBAAsB,CACpC,aAAa,EAAE,OAAO,EACtB,QAAQ,EAAE,WAAW,GACpB,WAAW,EAAE,CAUf;AAgCD,gBAAgB;AAChB,wBAAgB,WAAW,CAAC,OAAO,EAAE,KAAK,CAAC,WAAW,CAAC,GAAG,SAAS,6BAelE"}
@@ -1,67 +1,67 @@
1
- export declare const monitorFrequency = 2000;
2
- interface SenderStats {
3
- /** number of packets sent */
4
- packetsSent?: number;
5
- /** number of bytes sent */
6
- bytesSent?: number;
7
- /** jitter as perceived by remote */
8
- jitter?: number;
9
- /** packets reported lost by remote */
10
- packetsLost?: number;
11
- /** RTT reported by remote */
12
- roundTripTime?: number;
13
- /** ID of the outbound stream */
14
- streamId?: string;
15
- timestamp: number;
16
- }
17
- export interface AudioSenderStats extends SenderStats {
18
- type: 'audio';
19
- }
20
- export interface VideoSenderStats extends SenderStats {
21
- type: 'video';
22
- firCount: number;
23
- pliCount: number;
24
- nackCount: number;
25
- rid: string;
26
- frameWidth: number;
27
- frameHeight: number;
28
- framesSent: number;
29
- qualityLimitationReason: string;
30
- qualityLimitationResolutionChanges: number;
31
- retransmittedPacketsSent: number;
32
- }
33
- interface ReceiverStats {
34
- jitterBufferDelay?: number;
35
- /** packets reported lost by remote */
36
- packetsLost?: number;
37
- /** number of packets sent */
38
- packetsReceived?: number;
39
- bytesReceived?: number;
40
- streamId?: string;
41
- jitter?: number;
42
- timestamp: number;
43
- }
44
- export interface AudioReceiverStats extends ReceiverStats {
45
- type: 'audio';
46
- concealedSamples?: number;
47
- concealmentEvents?: number;
48
- silentConcealedSamples?: number;
49
- silentConcealmentEvents?: number;
50
- totalAudioEnergy?: number;
51
- totalSamplesDuration?: number;
52
- }
53
- export interface VideoReceiverStats extends ReceiverStats {
54
- type: 'video';
55
- framesDecoded: number;
56
- framesDropped: number;
57
- framesReceived: number;
58
- frameWidth?: number;
59
- frameHeight?: number;
60
- firCount?: number;
61
- pliCount?: number;
62
- nackCount?: number;
63
- decoderImplementation?: string;
64
- }
65
- export declare function computeBitrate<T extends ReceiverStats | SenderStats>(currentStats: T, prevStats?: T): number;
66
- export {};
1
+ export declare const monitorFrequency = 2000;
2
+ interface SenderStats {
3
+ /** number of packets sent */
4
+ packetsSent?: number;
5
+ /** number of bytes sent */
6
+ bytesSent?: number;
7
+ /** jitter as perceived by remote */
8
+ jitter?: number;
9
+ /** packets reported lost by remote */
10
+ packetsLost?: number;
11
+ /** RTT reported by remote */
12
+ roundTripTime?: number;
13
+ /** ID of the outbound stream */
14
+ streamId?: string;
15
+ timestamp: number;
16
+ }
17
+ export interface AudioSenderStats extends SenderStats {
18
+ type: 'audio';
19
+ }
20
+ export interface VideoSenderStats extends SenderStats {
21
+ type: 'video';
22
+ firCount: number;
23
+ pliCount: number;
24
+ nackCount: number;
25
+ rid: string;
26
+ frameWidth: number;
27
+ frameHeight: number;
28
+ framesSent: number;
29
+ qualityLimitationReason: string;
30
+ qualityLimitationResolutionChanges: number;
31
+ retransmittedPacketsSent: number;
32
+ }
33
+ interface ReceiverStats {
34
+ jitterBufferDelay?: number;
35
+ /** packets reported lost by remote */
36
+ packetsLost?: number;
37
+ /** number of packets sent */
38
+ packetsReceived?: number;
39
+ bytesReceived?: number;
40
+ streamId?: string;
41
+ jitter?: number;
42
+ timestamp: number;
43
+ }
44
+ export interface AudioReceiverStats extends ReceiverStats {
45
+ type: 'audio';
46
+ concealedSamples?: number;
47
+ concealmentEvents?: number;
48
+ silentConcealedSamples?: number;
49
+ silentConcealmentEvents?: number;
50
+ totalAudioEnergy?: number;
51
+ totalSamplesDuration?: number;
52
+ }
53
+ export interface VideoReceiverStats extends ReceiverStats {
54
+ type: 'video';
55
+ framesDecoded: number;
56
+ framesDropped: number;
57
+ framesReceived: number;
58
+ frameWidth?: number;
59
+ frameHeight?: number;
60
+ firCount?: number;
61
+ pliCount?: number;
62
+ nackCount?: number;
63
+ decoderImplementation?: string;
64
+ }
65
+ export declare function computeBitrate<T extends ReceiverStats | SenderStats>(currentStats: T, prevStats?: T): number;
66
+ export {};
67
67
  //# sourceMappingURL=stats.d.ts.map
@@ -1,13 +1,12 @@
1
- /// <reference types="node" />
2
- /**
3
- * Timers that can be overridden with platform specific implementations
4
- * that ensure that they are fired. These should be used when it is critical
5
- * that the timer fires on time.
6
- */
7
- export default class CriticalTimers {
8
- static setTimeout: (callback: (args: void) => void, ms?: number | undefined) => NodeJS.Timeout;
9
- static setInterval: (callback: (args: void) => void, ms?: number | undefined) => NodeJS.Timer;
10
- static clearTimeout: (timeoutId: NodeJS.Timeout) => void;
11
- static clearInterval: (intervalId: NodeJS.Timeout) => void;
12
- }
1
+ /**
2
+ * Timers that can be overridden with platform specific implementations
3
+ * that ensure that they are fired. These should be used when it is critical
4
+ * that the timer fires on time.
5
+ */
6
+ export default class CriticalTimers {
7
+ static setTimeout: (handler: TimerHandler, timeout?: number | undefined, ...arguments: any[]) => number;
8
+ static setInterval: (handler: TimerHandler, timeout?: number | undefined, ...arguments: any[]) => number;
9
+ static clearTimeout: (id: number | undefined) => void;
10
+ static clearInterval: (id: number | undefined) => void;
11
+ }
13
12
  //# sourceMappingURL=timers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"timers.d.ts","sourceRoot":"","sources":["../../../src/room/timers.ts"],"names":[],"mappings":";AAAA;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,cAAc;IAEjC,MAAM,CAAC,UAAU,8EAAmE;IAGpF,MAAM,CAAC,WAAW,4EAAqE;IAEvF,MAAM,CAAC,YAAY,sCAAuE;IAE1F,MAAM,CAAC,aAAa,uCAAyE;CAC9F"}
1
+ {"version":3,"file":"timers.d.ts","sourceRoot":"","sources":["../../../src/room/timers.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,cAAc;IAEjC,MAAM,CAAC,UAAU,uFAAmE;IAGpF,MAAM,CAAC,WAAW,uFAAqE;IAEvF,MAAM,CAAC,YAAY,mCAAuE;IAE1F,MAAM,CAAC,aAAa,mCAAyE;CAC9F"}
@@ -1,25 +1,25 @@
1
- import { AudioSenderStats } from '../stats';
2
- import LocalTrack from './LocalTrack';
3
- import type { AudioCaptureOptions } from './options';
4
- export default class LocalAudioTrack extends LocalTrack {
5
- /** @internal */
6
- stopOnMute: boolean;
7
- private prevStats?;
8
- /**
9
- *
10
- * @param mediaTrack
11
- * @param constraints MediaTrackConstraints that are being used when restarting or reacquiring tracks
12
- * @param userProvidedTrack Signals to the SDK whether or not the mediaTrack should be managed (i.e. released and reacquired) internally by the SDK
13
- */
14
- constructor(mediaTrack: MediaStreamTrack, constraints?: MediaTrackConstraints, userProvidedTrack?: boolean);
15
- setDeviceId(deviceId: ConstrainDOMString): Promise<void>;
16
- mute(): Promise<LocalAudioTrack>;
17
- unmute(): Promise<LocalAudioTrack>;
18
- restartTrack(options?: AudioCaptureOptions): Promise<void>;
19
- protected restart(constraints?: MediaTrackConstraints): Promise<LocalTrack>;
20
- startMonitor(): void;
21
- protected monitorSender: () => Promise<void>;
22
- getSenderStats(): Promise<AudioSenderStats | undefined>;
23
- checkForSilence(): Promise<boolean>;
24
- }
1
+ import type { AudioSenderStats } from '../stats';
2
+ import LocalTrack from './LocalTrack';
3
+ import type { AudioCaptureOptions } from './options';
4
+ export default class LocalAudioTrack extends LocalTrack {
5
+ /** @internal */
6
+ stopOnMute: boolean;
7
+ private prevStats?;
8
+ /**
9
+ *
10
+ * @param mediaTrack
11
+ * @param constraints MediaTrackConstraints that are being used when restarting or reacquiring tracks
12
+ * @param userProvidedTrack Signals to the SDK whether or not the mediaTrack should be managed (i.e. released and reacquired) internally by the SDK
13
+ */
14
+ constructor(mediaTrack: MediaStreamTrack, constraints?: MediaTrackConstraints, userProvidedTrack?: boolean);
15
+ setDeviceId(deviceId: ConstrainDOMString): Promise<void>;
16
+ mute(): Promise<LocalAudioTrack>;
17
+ unmute(): Promise<LocalAudioTrack>;
18
+ restartTrack(options?: AudioCaptureOptions): Promise<void>;
19
+ protected restart(constraints?: MediaTrackConstraints): Promise<LocalTrack>;
20
+ startMonitor(): void;
21
+ protected monitorSender: () => Promise<void>;
22
+ getSenderStats(): Promise<AudioSenderStats | undefined>;
23
+ checkForSilence(): Promise<boolean>;
24
+ }
25
25
  //# sourceMappingURL=LocalAudioTrack.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"LocalAudioTrack.d.ts","sourceRoot":"","sources":["../../../../src/room/track/LocalAudioTrack.ts"],"names":[],"mappings":"AAEA,OAAO,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AAW,CAAC,QAAQ,EAAE,kBAAkB;IAUxC,IAAI,IAAI,OAAO,CAAC,eAAe,CAAC;IAgBhC,MAAM,IAAI,OAAO,CAAC,eAAe,CAAC;IAmBlC,YAAY,CAAC,OAAO,CAAC,EAAE,mBAAmB;cAWhC,OAAO,CAAC,WAAW,CAAC,EAAE,qBAAqB,GAAG,OAAO,CAAC,UAAU,CAAC;IAOjF,YAAY;IAYZ,SAAS,CAAC,aAAa,sBAmBrB;IAEI,cAAc,IAAI,OAAO,CAAC,gBAAgB,GAAG,SAAS,CAAC;IAyBvD,eAAe;CAUtB"}
@@ -1,44 +1,44 @@
1
- import { Mutex } from '../utils';
2
- import { Track } from './Track';
3
- import type { VideoCodec } from './options';
4
- export default abstract class LocalTrack extends Track {
5
- /** @internal */
6
- sender?: RTCRtpSender;
7
- /** @internal */
8
- codec?: VideoCodec;
9
- protected constraints: MediaTrackConstraints;
10
- protected reacquireTrack: boolean;
11
- protected providedByUser: boolean;
12
- protected muteLock: Mutex;
13
- protected pauseUpstreamLock: Mutex;
14
- /**
15
- *
16
- * @param mediaTrack
17
- * @param kind
18
- * @param constraints MediaTrackConstraints that are being used when restarting or reacquiring tracks
19
- * @param userProvidedTrack Signals to the SDK whether or not the mediaTrack should be managed (i.e. released and reacquired) internally by the SDK
20
- */
21
- protected constructor(mediaTrack: MediaStreamTrack, kind: Track.Kind, constraints?: MediaTrackConstraints, userProvidedTrack?: boolean);
22
- get id(): string;
23
- get dimensions(): Track.Dimensions | undefined;
24
- private _isUpstreamPaused;
25
- get isUpstreamPaused(): boolean;
26
- get isUserProvided(): boolean;
27
- waitForDimensions(timeout?: number): Promise<Track.Dimensions>;
28
- /**
29
- * @returns DeviceID of the device that is currently being used for this track
30
- */
31
- getDeviceId(): Promise<string | undefined>;
32
- mute(): Promise<LocalTrack>;
33
- unmute(): Promise<LocalTrack>;
34
- replaceTrack(track: MediaStreamTrack, userProvidedTrack?: boolean): Promise<LocalTrack>;
35
- protected restart(constraints?: MediaTrackConstraints): Promise<LocalTrack>;
36
- protected setTrackMuted(muted: boolean): void;
37
- protected get needsReAcquisition(): boolean;
38
- protected handleAppVisibilityChanged(): Promise<void>;
39
- private handleEnded;
40
- pauseUpstream(): Promise<void>;
41
- resumeUpstream(): Promise<void>;
42
- protected abstract monitorSender(): void;
43
- }
1
+ import { Mutex } from '../utils';
2
+ import { Track } from './Track';
3
+ import type { VideoCodec } from './options';
4
+ export default abstract class LocalTrack extends Track {
5
+ /** @internal */
6
+ sender?: RTCRtpSender;
7
+ /** @internal */
8
+ codec?: VideoCodec;
9
+ protected constraints: MediaTrackConstraints;
10
+ protected reacquireTrack: boolean;
11
+ protected providedByUser: boolean;
12
+ protected muteLock: Mutex;
13
+ protected pauseUpstreamLock: Mutex;
14
+ /**
15
+ *
16
+ * @param mediaTrack
17
+ * @param kind
18
+ * @param constraints MediaTrackConstraints that are being used when restarting or reacquiring tracks
19
+ * @param userProvidedTrack Signals to the SDK whether or not the mediaTrack should be managed (i.e. released and reacquired) internally by the SDK
20
+ */
21
+ protected constructor(mediaTrack: MediaStreamTrack, kind: Track.Kind, constraints?: MediaTrackConstraints, userProvidedTrack?: boolean);
22
+ get id(): string;
23
+ get dimensions(): Track.Dimensions | undefined;
24
+ private _isUpstreamPaused;
25
+ get isUpstreamPaused(): boolean;
26
+ get isUserProvided(): boolean;
27
+ waitForDimensions(timeout?: number): Promise<Track.Dimensions>;
28
+ /**
29
+ * @returns DeviceID of the device that is currently being used for this track
30
+ */
31
+ getDeviceId(): Promise<string | undefined>;
32
+ mute(): Promise<LocalTrack>;
33
+ unmute(): Promise<LocalTrack>;
34
+ replaceTrack(track: MediaStreamTrack, userProvidedTrack?: boolean): Promise<LocalTrack>;
35
+ protected restart(constraints?: MediaTrackConstraints): Promise<LocalTrack>;
36
+ protected setTrackMuted(muted: boolean): void;
37
+ protected get needsReAcquisition(): boolean;
38
+ protected handleAppVisibilityChanged(): Promise<void>;
39
+ private handleEnded;
40
+ pauseUpstream(): Promise<void>;
41
+ resumeUpstream(): Promise<void>;
42
+ protected abstract monitorSender(): void;
43
+ }
44
44
  //# sourceMappingURL=LocalTrack.d.ts.map
@@ -1,38 +1,38 @@
1
- import type { TrackInfo } from '../../proto/livekit_models';
2
- import type LocalAudioTrack from './LocalAudioTrack';
3
- import type LocalTrack from './LocalTrack';
4
- import type LocalVideoTrack from './LocalVideoTrack';
5
- import type { Track } from './Track';
6
- import { TrackPublication } from './TrackPublication';
7
- import type { TrackPublishOptions } from './options';
8
- export default class LocalTrackPublication extends TrackPublication {
9
- track?: LocalTrack;
10
- options?: TrackPublishOptions;
11
- get isUpstreamPaused(): boolean | undefined;
12
- constructor(kind: Track.Kind, ti: TrackInfo, track?: LocalTrack);
13
- setTrack(track?: Track): void;
14
- get isMuted(): boolean;
15
- get audioTrack(): LocalAudioTrack | undefined;
16
- get videoTrack(): LocalVideoTrack | undefined;
17
- /**
18
- * Mute the track associated with this publication
19
- */
20
- mute(): Promise<LocalTrack | undefined>;
21
- /**
22
- * Unmute track associated with this publication
23
- */
24
- unmute(): Promise<LocalTrack | undefined>;
25
- /**
26
- * Pauses the media stream track associated with this publication from being sent to the server
27
- * and signals "muted" event to other participants
28
- * Useful if you want to pause the stream without pausing the local media stream track
29
- */
30
- pauseUpstream(): Promise<void>;
31
- /**
32
- * Resumes sending the media stream track associated with this publication to the server after a call to [[pauseUpstream()]]
33
- * and signals "unmuted" event to other participants (unless the track is explicitly muted)
34
- */
35
- resumeUpstream(): Promise<void>;
36
- handleTrackEnded: () => void;
37
- }
1
+ import type { TrackInfo } from '../../proto/livekit_models';
2
+ import type LocalAudioTrack from './LocalAudioTrack';
3
+ import type LocalTrack from './LocalTrack';
4
+ import type LocalVideoTrack from './LocalVideoTrack';
5
+ import type { Track } from './Track';
6
+ import { TrackPublication } from './TrackPublication';
7
+ import type { TrackPublishOptions } from './options';
8
+ export default class LocalTrackPublication extends TrackPublication {
9
+ track?: LocalTrack;
10
+ options?: TrackPublishOptions;
11
+ get isUpstreamPaused(): boolean | undefined;
12
+ constructor(kind: Track.Kind, ti: TrackInfo, track?: LocalTrack);
13
+ setTrack(track?: Track): void;
14
+ get isMuted(): boolean;
15
+ get audioTrack(): LocalAudioTrack | undefined;
16
+ get videoTrack(): LocalVideoTrack | undefined;
17
+ /**
18
+ * Mute the track associated with this publication
19
+ */
20
+ mute(): Promise<LocalTrack | undefined>;
21
+ /**
22
+ * Unmute track associated with this publication
23
+ */
24
+ unmute(): Promise<LocalTrack | undefined>;
25
+ /**
26
+ * Pauses the media stream track associated with this publication from being sent to the server
27
+ * and signals "muted" event to other participants
28
+ * Useful if you want to pause the stream without pausing the local media stream track
29
+ */
30
+ pauseUpstream(): Promise<void>;
31
+ /**
32
+ * Resumes sending the media stream track associated with this publication to the server after a call to [[pauseUpstream()]]
33
+ * and signals "unmuted" event to other participants (unless the track is explicitly muted)
34
+ */
35
+ resumeUpstream(): Promise<void>;
36
+ handleTrackEnded: () => void;
37
+ }
38
38
  //# sourceMappingURL=LocalTrackPublication.d.ts.map