livekit-client 0.18.4-RC8 → 0.18.6

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.
Files changed (127) hide show
  1. package/README.md +2 -5
  2. package/dist/api/RequestQueue.d.ts +13 -12
  3. package/dist/api/RequestQueue.d.ts.map +1 -0
  4. package/dist/api/SignalClient.d.ts +67 -66
  5. package/dist/api/SignalClient.d.ts.map +1 -0
  6. package/dist/connect.d.ts +24 -23
  7. package/dist/connect.d.ts.map +1 -0
  8. package/dist/index.d.ts +27 -26
  9. package/dist/index.d.ts.map +1 -0
  10. package/dist/livekit-client.esm.mjs +593 -507
  11. package/dist/livekit-client.esm.mjs.map +1 -1
  12. package/dist/livekit-client.umd.js +1 -1
  13. package/dist/livekit-client.umd.js.map +1 -1
  14. package/dist/logger.d.ts +26 -25
  15. package/dist/logger.d.ts.map +1 -0
  16. package/dist/options.d.ts +128 -127
  17. package/dist/options.d.ts.map +1 -0
  18. package/dist/proto/google/protobuf/timestamp.d.ts +133 -132
  19. package/dist/proto/google/protobuf/timestamp.d.ts.map +1 -0
  20. package/dist/proto/livekit_models.d.ts +876 -875
  21. package/dist/proto/livekit_models.d.ts.map +1 -0
  22. package/dist/proto/livekit_rtc.d.ts +3904 -3903
  23. package/dist/proto/livekit_rtc.d.ts.map +1 -0
  24. package/dist/room/DeviceManager.d.ts +8 -7
  25. package/dist/room/DeviceManager.d.ts.map +1 -0
  26. package/dist/room/PCTransport.d.ts +16 -15
  27. package/dist/room/PCTransport.d.ts.map +1 -0
  28. package/dist/room/RTCEngine.d.ts +67 -66
  29. package/dist/room/RTCEngine.d.ts.map +1 -0
  30. package/dist/room/Room.d.ts +166 -165
  31. package/dist/room/Room.d.ts.map +1 -0
  32. package/dist/room/errors.d.ts +29 -28
  33. package/dist/room/errors.d.ts.map +1 -0
  34. package/dist/room/events.d.ts +391 -390
  35. package/dist/room/events.d.ts.map +1 -0
  36. package/dist/room/participant/LocalParticipant.d.ts +126 -125
  37. package/dist/room/participant/LocalParticipant.d.ts.map +1 -0
  38. package/dist/room/participant/Participant.d.ts +94 -93
  39. package/dist/room/participant/Participant.d.ts.map +1 -0
  40. package/dist/room/participant/ParticipantTrackPermission.d.ts +26 -25
  41. package/dist/room/participant/ParticipantTrackPermission.d.ts.map +1 -0
  42. package/dist/room/participant/RemoteParticipant.d.ts +40 -39
  43. package/dist/room/participant/RemoteParticipant.d.ts.map +1 -0
  44. package/dist/room/participant/publishUtils.d.ts +18 -17
  45. package/dist/room/participant/publishUtils.d.ts.map +1 -0
  46. package/dist/room/stats.d.ts +66 -65
  47. package/dist/room/stats.d.ts.map +1 -0
  48. package/dist/room/track/LocalAudioTrack.d.ts +20 -19
  49. package/dist/room/track/LocalAudioTrack.d.ts.map +1 -0
  50. package/dist/room/track/LocalTrack.d.ts +28 -27
  51. package/dist/room/track/LocalTrack.d.ts.map +1 -0
  52. package/dist/room/track/LocalTrackPublication.d.ts +38 -37
  53. package/dist/room/track/LocalTrackPublication.d.ts.map +1 -0
  54. package/dist/room/track/LocalVideoTrack.d.ts +31 -30
  55. package/dist/room/track/LocalVideoTrack.d.ts.map +1 -0
  56. package/dist/room/track/RemoteAudioTrack.d.ts +20 -19
  57. package/dist/room/track/RemoteAudioTrack.d.ts.map +1 -0
  58. package/dist/room/track/RemoteTrack.d.ts +16 -15
  59. package/dist/room/track/RemoteTrack.d.ts.map +1 -0
  60. package/dist/room/track/RemoteTrackPublication.d.ts +51 -50
  61. package/dist/room/track/RemoteTrackPublication.d.ts.map +1 -0
  62. package/dist/room/track/RemoteVideoTrack.d.ts +30 -27
  63. package/dist/room/track/RemoteVideoTrack.d.ts.map +1 -0
  64. package/dist/room/track/Track.d.ts +105 -100
  65. package/dist/room/track/Track.d.ts.map +1 -0
  66. package/dist/room/track/TrackPublication.d.ts +50 -49
  67. package/dist/room/track/TrackPublication.d.ts.map +1 -0
  68. package/dist/room/track/create.d.ts +24 -23
  69. package/dist/room/track/create.d.ts.map +1 -0
  70. package/dist/room/track/defaults.d.ts +5 -4
  71. package/dist/room/track/defaults.d.ts.map +1 -0
  72. package/dist/room/track/options.d.ts +232 -222
  73. package/dist/room/track/options.d.ts.map +1 -0
  74. package/dist/room/track/types.d.ts +19 -18
  75. package/dist/room/track/types.d.ts.map +1 -0
  76. package/dist/room/track/utils.d.ts +14 -13
  77. package/dist/room/track/utils.d.ts.map +1 -0
  78. package/dist/room/utils.d.ts +17 -16
  79. package/dist/room/utils.d.ts.map +1 -0
  80. package/dist/test/mocks.d.ts +12 -11
  81. package/dist/test/mocks.d.ts.map +1 -0
  82. package/dist/version.d.ts +3 -2
  83. package/dist/version.d.ts.map +1 -0
  84. package/package.json +6 -6
  85. package/src/api/RequestQueue.ts +53 -0
  86. package/src/api/SignalClient.ts +497 -0
  87. package/src/connect.ts +98 -0
  88. package/src/index.ts +49 -0
  89. package/src/logger.ts +56 -0
  90. package/src/options.ts +156 -0
  91. package/src/proto/google/protobuf/timestamp.ts +216 -0
  92. package/src/proto/livekit_models.ts +2456 -0
  93. package/src/proto/livekit_rtc.ts +2859 -0
  94. package/src/room/DeviceManager.ts +80 -0
  95. package/src/room/PCTransport.ts +88 -0
  96. package/src/room/RTCEngine.ts +695 -0
  97. package/src/room/Room.ts +970 -0
  98. package/src/room/errors.ts +65 -0
  99. package/src/room/events.ts +438 -0
  100. package/src/room/participant/LocalParticipant.ts +779 -0
  101. package/src/room/participant/Participant.ts +287 -0
  102. package/src/room/participant/ParticipantTrackPermission.ts +42 -0
  103. package/src/room/participant/RemoteParticipant.ts +263 -0
  104. package/src/room/participant/publishUtils.test.ts +144 -0
  105. package/src/room/participant/publishUtils.ts +258 -0
  106. package/src/room/stats.ts +134 -0
  107. package/src/room/track/LocalAudioTrack.ts +134 -0
  108. package/src/room/track/LocalTrack.ts +229 -0
  109. package/src/room/track/LocalTrackPublication.ts +87 -0
  110. package/src/room/track/LocalVideoTrack.test.ts +72 -0
  111. package/src/room/track/LocalVideoTrack.ts +295 -0
  112. package/src/room/track/RemoteAudioTrack.ts +86 -0
  113. package/src/room/track/RemoteTrack.ts +62 -0
  114. package/src/room/track/RemoteTrackPublication.ts +207 -0
  115. package/src/room/track/RemoteVideoTrack.ts +253 -0
  116. package/src/room/track/Track.ts +365 -0
  117. package/src/room/track/TrackPublication.ts +120 -0
  118. package/src/room/track/create.ts +122 -0
  119. package/src/room/track/defaults.ts +26 -0
  120. package/src/room/track/options.ts +292 -0
  121. package/src/room/track/types.ts +20 -0
  122. package/src/room/track/utils.test.ts +110 -0
  123. package/src/room/track/utils.ts +113 -0
  124. package/src/room/utils.ts +115 -0
  125. package/src/test/mocks.ts +17 -0
  126. package/src/version.ts +2 -0
  127. package/CHANGELOG.md +0 -5
@@ -1,222 +1,232 @@
1
- import { Track } from './Track';
2
- export interface TrackPublishDefaults {
3
- /**
4
- * encoding parameters for camera track
5
- */
6
- videoEncoding?: VideoEncoding;
7
- /**
8
- * encoding parameters for screen share track
9
- */
10
- screenShareEncoding?: VideoEncoding;
11
- /**
12
- * codec, defaults to vp8
13
- */
14
- videoCodec?: VideoCodec;
15
- /**
16
- * max audio bitrate, defaults to [[AudioPresets.speech]]
17
- */
18
- audioBitrate?: number;
19
- /**
20
- * dtx (Discontinuous Transmission of audio), defaults to true
21
- */
22
- dtx?: boolean;
23
- /**
24
- * use simulcast, defaults to true.
25
- * When using simulcast, LiveKit will publish up to three versions of the stream
26
- * at various resolutions.
27
- */
28
- simulcast?: boolean;
29
- /**
30
- * custom video simulcast layers for camera tracks, defaults to h180, h360, h540
31
- * You can specify up to two custom layers that will be used instead of
32
- * the LiveKit default layers.
33
- * Note: the layers need to be ordered from lowest to highest quality
34
- */
35
- videoSimulcastLayers?: Array<VideoPreset>;
36
- /**
37
- * custom video simulcast layers for screen tracks
38
- * Note: the layers need to be ordered from lowest to highest quality
39
- */
40
- screenShareSimulcastLayers?: Array<VideoPreset>;
41
- /**
42
- * For local tracks, stop the underlying MediaStreamTrack when the track is muted (or paused)
43
- * on some platforms, this option is necessary to disable the microphone recording indicator.
44
- * Note: when this is enabled, and BT devices are connected, they will transition between
45
- * profiles (e.g. HFP to A2DP) and there will be an audible difference in playback.
46
- *
47
- * defaults to false
48
- */
49
- stopMicTrackOnMute?: boolean;
50
- }
51
- /**
52
- * Options when publishing tracks
53
- */
54
- export interface TrackPublishOptions extends TrackPublishDefaults {
55
- /**
56
- * set a track name
57
- */
58
- name?: string;
59
- /**
60
- * Source of track, camera, microphone, or screen
61
- */
62
- source?: Track.Source;
63
- }
64
- export interface CreateLocalTracksOptions {
65
- /**
66
- * audio track options, true to create with defaults. false if audio shouldn't be created
67
- * default true
68
- */
69
- audio?: boolean | AudioCaptureOptions;
70
- /**
71
- * video track options, true to create with defaults. false if video shouldn't be created
72
- * default true
73
- */
74
- video?: boolean | VideoCaptureOptions;
75
- }
76
- export interface VideoCaptureOptions {
77
- /**
78
- * A ConstrainDOMString object specifying a device ID or an array of device
79
- * IDs which are acceptable and/or required.
80
- */
81
- deviceId?: ConstrainDOMString;
82
- /**
83
- * a facing or an array of facings which are acceptable and/or required.
84
- */
85
- facingMode?: 'user' | 'environment' | 'left' | 'right';
86
- resolution?: VideoResolution;
87
- }
88
- export interface ScreenShareCaptureOptions {
89
- /**
90
- * true to capture audio shared. browser support for audio capturing in
91
- * screenshare is limited: https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getDisplayMedia#browser_compatibility
92
- */
93
- audio?: boolean;
94
- /** capture resolution, defaults to full HD */
95
- resolution?: VideoResolution;
96
- }
97
- export interface AudioCaptureOptions {
98
- /**
99
- * specifies whether automatic gain control is preferred and/or required
100
- */
101
- autoGainControl?: ConstrainBoolean;
102
- /**
103
- * the channel count or range of channel counts which are acceptable and/or required
104
- */
105
- channelCount?: ConstrainULong;
106
- /**
107
- * A ConstrainDOMString object specifying a device ID or an array of device
108
- * IDs which are acceptable and/or required.
109
- */
110
- deviceId?: ConstrainDOMString;
111
- /**
112
- * whether or not echo cancellation is preferred and/or required
113
- */
114
- echoCancellation?: ConstrainBoolean;
115
- /**
116
- * the latency or range of latencies which are acceptable and/or required.
117
- */
118
- latency?: ConstrainDouble;
119
- /**
120
- * whether noise suppression is preferred and/or required.
121
- */
122
- noiseSuppression?: ConstrainBoolean;
123
- /**
124
- * the sample rate or range of sample rates which are acceptable and/or required.
125
- */
126
- sampleRate?: ConstrainULong;
127
- /**
128
- * sample size or range of sample sizes which are acceptable and/or required.
129
- */
130
- sampleSize?: ConstrainULong;
131
- }
132
- export interface VideoResolution {
133
- width: number;
134
- height: number;
135
- frameRate?: number;
136
- aspectRatio?: number;
137
- }
138
- export interface VideoEncoding {
139
- maxBitrate: number;
140
- maxFramerate?: number;
141
- }
142
- export declare class VideoPreset {
143
- encoding: VideoEncoding;
144
- width: number;
145
- height: number;
146
- constructor(width: number, height: number, maxBitrate: number, maxFramerate?: number);
147
- get resolution(): VideoResolution;
148
- }
149
- export interface AudioPreset {
150
- maxBitrate: number;
151
- }
152
- export declare type VideoCodec = 'vp8' | 'h264' | 'av1' | 'vp9';
153
- export declare namespace AudioPresets {
154
- const telephone: AudioPreset;
155
- const speech: AudioPreset;
156
- const music: AudioPreset;
157
- }
158
- /**
159
- * Sane presets for video resolution/encoding
160
- */
161
- export declare const VideoPresets: {
162
- readonly h90: VideoPreset;
163
- readonly h180: VideoPreset;
164
- readonly h216: VideoPreset;
165
- readonly h360: VideoPreset;
166
- readonly h540: VideoPreset;
167
- readonly h720: VideoPreset;
168
- readonly h1080: VideoPreset;
169
- readonly h1440: VideoPreset;
170
- readonly h2160: VideoPreset;
171
- /** @deprecated */
172
- readonly qvga: VideoPreset;
173
- /** @deprecated */
174
- readonly vga: VideoPreset;
175
- /** @deprecated */
176
- readonly qhd: VideoPreset;
177
- /** @deprecated */
178
- readonly hd: VideoPreset;
179
- /** @deprecated */
180
- readonly fhd: VideoPreset;
181
- };
182
- /**
183
- * Four by three presets
184
- */
185
- export declare const VideoPresets43: {
186
- readonly h120: VideoPreset;
187
- readonly h180: VideoPreset;
188
- readonly h240: VideoPreset;
189
- readonly h360: VideoPreset;
190
- readonly h480: VideoPreset;
191
- readonly h540: VideoPreset;
192
- readonly h720: VideoPreset;
193
- readonly h1080: VideoPreset;
194
- readonly h1440: VideoPreset;
195
- /** @deprecated */
196
- readonly qvga: VideoPreset;
197
- /** @deprecated */
198
- readonly vga: VideoPreset;
199
- /** @deprecated */
200
- readonly qhd: VideoPreset;
201
- /** @deprecated */
202
- readonly hd: VideoPreset;
203
- /** @deprecated */
204
- readonly fhd: VideoPreset;
205
- };
206
- export declare const ScreenSharePresets: {
207
- readonly h360fps3: VideoPreset;
208
- readonly h720fps5: VideoPreset;
209
- readonly h720fps15: VideoPreset;
210
- readonly h1080fps15: VideoPreset;
211
- readonly h1080fps30: VideoPreset;
212
- /** @deprecated */
213
- readonly vga: VideoPreset;
214
- /** @deprecated */
215
- readonly hd_8: VideoPreset;
216
- /** @deprecated */
217
- readonly hd_15: VideoPreset;
218
- /** @deprecated */
219
- readonly fhd_15: VideoPreset;
220
- /** @deprecated */
221
- readonly fhd_30: VideoPreset;
222
- };
1
+ import { Track } from './Track';
2
+ export interface TrackPublishDefaults {
3
+ /**
4
+ * encoding parameters for camera track
5
+ */
6
+ videoEncoding?: VideoEncoding;
7
+ /**
8
+ * encoding parameters for screen share track
9
+ */
10
+ screenShareEncoding?: VideoEncoding;
11
+ /**
12
+ * codec, defaults to vp8
13
+ */
14
+ videoCodec?: VideoCodec;
15
+ /**
16
+ * max audio bitrate, defaults to [[AudioPresets.speech]]
17
+ */
18
+ audioBitrate?: number;
19
+ /**
20
+ * dtx (Discontinuous Transmission of audio), defaults to true
21
+ */
22
+ dtx?: boolean;
23
+ /**
24
+ * use simulcast, defaults to true.
25
+ * When using simulcast, LiveKit will publish up to three versions of the stream
26
+ * at various resolutions.
27
+ */
28
+ simulcast?: boolean;
29
+ /**
30
+ * scalability mode for svc codecs, defaults to 'L3T3'.
31
+ * for svc codecs, simulcast is disabled.
32
+ */
33
+ scalabilityMode?: ScalabilityMode;
34
+ /**
35
+ * custom video simulcast layers for camera tracks, defaults to h180, h360, h540
36
+ * You can specify up to two custom layers that will be used instead of
37
+ * the LiveKit default layers.
38
+ * Note: the layers need to be ordered from lowest to highest quality
39
+ */
40
+ videoSimulcastLayers?: Array<VideoPreset>;
41
+ /**
42
+ * custom video simulcast layers for screen tracks
43
+ * Note: the layers need to be ordered from lowest to highest quality
44
+ */
45
+ screenShareSimulcastLayers?: Array<VideoPreset>;
46
+ /**
47
+ * For local tracks, stop the underlying MediaStreamTrack when the track is muted (or paused)
48
+ * on some platforms, this option is necessary to disable the microphone recording indicator.
49
+ * Note: when this is enabled, and BT devices are connected, they will transition between
50
+ * profiles (e.g. HFP to A2DP) and there will be an audible difference in playback.
51
+ *
52
+ * defaults to false
53
+ */
54
+ stopMicTrackOnMute?: boolean;
55
+ }
56
+ /**
57
+ * Options when publishing tracks
58
+ */
59
+ export interface TrackPublishOptions extends TrackPublishDefaults {
60
+ /**
61
+ * set a track name
62
+ */
63
+ name?: string;
64
+ /**
65
+ * Source of track, camera, microphone, or screen
66
+ */
67
+ source?: Track.Source;
68
+ }
69
+ export interface CreateLocalTracksOptions {
70
+ /**
71
+ * audio track options, true to create with defaults. false if audio shouldn't be created
72
+ * default true
73
+ */
74
+ audio?: boolean | AudioCaptureOptions;
75
+ /**
76
+ * video track options, true to create with defaults. false if video shouldn't be created
77
+ * default true
78
+ */
79
+ video?: boolean | VideoCaptureOptions;
80
+ }
81
+ export interface VideoCaptureOptions {
82
+ /**
83
+ * A ConstrainDOMString object specifying a device ID or an array of device
84
+ * IDs which are acceptable and/or required.
85
+ */
86
+ deviceId?: ConstrainDOMString;
87
+ /**
88
+ * a facing or an array of facings which are acceptable and/or required.
89
+ */
90
+ facingMode?: 'user' | 'environment' | 'left' | 'right';
91
+ resolution?: VideoResolution;
92
+ }
93
+ export interface ScreenShareCaptureOptions {
94
+ /**
95
+ * true to capture audio shared. browser support for audio capturing in
96
+ * screenshare is limited: https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getDisplayMedia#browser_compatibility
97
+ */
98
+ audio?: boolean;
99
+ /** capture resolution, defaults to full HD */
100
+ resolution?: VideoResolution;
101
+ }
102
+ export interface AudioCaptureOptions {
103
+ /**
104
+ * specifies whether automatic gain control is preferred and/or required
105
+ */
106
+ autoGainControl?: ConstrainBoolean;
107
+ /**
108
+ * the channel count or range of channel counts which are acceptable and/or required
109
+ */
110
+ channelCount?: ConstrainULong;
111
+ /**
112
+ * A ConstrainDOMString object specifying a device ID or an array of device
113
+ * IDs which are acceptable and/or required.
114
+ */
115
+ deviceId?: ConstrainDOMString;
116
+ /**
117
+ * whether or not echo cancellation is preferred and/or required
118
+ */
119
+ echoCancellation?: ConstrainBoolean;
120
+ /**
121
+ * the latency or range of latencies which are acceptable and/or required.
122
+ */
123
+ latency?: ConstrainDouble;
124
+ /**
125
+ * whether noise suppression is preferred and/or required.
126
+ */
127
+ noiseSuppression?: ConstrainBoolean;
128
+ /**
129
+ * the sample rate or range of sample rates which are acceptable and/or required.
130
+ */
131
+ sampleRate?: ConstrainULong;
132
+ /**
133
+ * sample size or range of sample sizes which are acceptable and/or required.
134
+ */
135
+ sampleSize?: ConstrainULong;
136
+ }
137
+ export interface VideoResolution {
138
+ width: number;
139
+ height: number;
140
+ frameRate?: number;
141
+ aspectRatio?: number;
142
+ }
143
+ export interface VideoEncoding {
144
+ maxBitrate: number;
145
+ maxFramerate?: number;
146
+ }
147
+ export declare class VideoPreset {
148
+ encoding: VideoEncoding;
149
+ width: number;
150
+ height: number;
151
+ constructor(width: number, height: number, maxBitrate: number, maxFramerate?: number);
152
+ get resolution(): VideoResolution;
153
+ }
154
+ export interface AudioPreset {
155
+ maxBitrate: number;
156
+ }
157
+ export declare type VideoCodec = 'vp8' | 'h264' | 'av1' | 'vp9';
158
+ /**
159
+ * scalability modes for svc, only supprot l3t3 now.
160
+ */
161
+ export declare type ScalabilityMode = 'L3T3';
162
+ export declare namespace AudioPresets {
163
+ const telephone: AudioPreset;
164
+ const speech: AudioPreset;
165
+ const music: AudioPreset;
166
+ }
167
+ /**
168
+ * Sane presets for video resolution/encoding
169
+ */
170
+ export declare const VideoPresets: {
171
+ readonly h90: VideoPreset;
172
+ readonly h180: VideoPreset;
173
+ readonly h216: VideoPreset;
174
+ readonly h360: VideoPreset;
175
+ readonly h540: VideoPreset;
176
+ readonly h720: VideoPreset;
177
+ readonly h1080: VideoPreset;
178
+ readonly h1440: VideoPreset;
179
+ readonly h2160: VideoPreset;
180
+ /** @deprecated */
181
+ readonly qvga: VideoPreset;
182
+ /** @deprecated */
183
+ readonly vga: VideoPreset;
184
+ /** @deprecated */
185
+ readonly qhd: VideoPreset;
186
+ /** @deprecated */
187
+ readonly hd: VideoPreset;
188
+ /** @deprecated */
189
+ readonly fhd: VideoPreset;
190
+ };
191
+ /**
192
+ * Four by three presets
193
+ */
194
+ export declare const VideoPresets43: {
195
+ readonly h120: VideoPreset;
196
+ readonly h180: VideoPreset;
197
+ readonly h240: VideoPreset;
198
+ readonly h360: VideoPreset;
199
+ readonly h480: VideoPreset;
200
+ readonly h540: VideoPreset;
201
+ readonly h720: VideoPreset;
202
+ readonly h1080: VideoPreset;
203
+ readonly h1440: VideoPreset;
204
+ /** @deprecated */
205
+ readonly qvga: VideoPreset;
206
+ /** @deprecated */
207
+ readonly vga: VideoPreset;
208
+ /** @deprecated */
209
+ readonly qhd: VideoPreset;
210
+ /** @deprecated */
211
+ readonly hd: VideoPreset;
212
+ /** @deprecated */
213
+ readonly fhd: VideoPreset;
214
+ };
215
+ export declare const ScreenSharePresets: {
216
+ readonly h360fps3: VideoPreset;
217
+ readonly h720fps5: VideoPreset;
218
+ readonly h720fps15: VideoPreset;
219
+ readonly h1080fps15: VideoPreset;
220
+ readonly h1080fps30: VideoPreset;
221
+ /** @deprecated */
222
+ readonly vga: VideoPreset;
223
+ /** @deprecated */
224
+ readonly hd_8: VideoPreset;
225
+ /** @deprecated */
226
+ readonly hd_15: VideoPreset;
227
+ /** @deprecated */
228
+ readonly fhd_15: VideoPreset;
229
+ /** @deprecated */
230
+ readonly fhd_30: VideoPreset;
231
+ };
232
+ //# sourceMappingURL=options.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../../src/room/track/options.ts"],"names":[],"mappings":"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"}
@@ -1,18 +1,19 @@
1
- import type LocalAudioTrack from './LocalAudioTrack';
2
- import type LocalVideoTrack from './LocalVideoTrack';
3
- import type RemoteAudioTrack from './RemoteAudioTrack';
4
- import type RemoteVideoTrack from './RemoteVideoTrack';
5
- export declare type RemoteTrack = RemoteAudioTrack | RemoteVideoTrack;
6
- export declare type AudioTrack = RemoteAudioTrack | LocalAudioTrack;
7
- export declare type VideoTrack = RemoteVideoTrack | LocalVideoTrack;
8
- export declare type AdaptiveStreamSettings = {
9
- /**
10
- * Set a custom pixel density, defaults to 1
11
- * When streaming videos on a ultra high definition screen this setting
12
- * let's you account for the devicePixelRatio of those screens.
13
- * Set it to `screen` to use the actual pixel density of the screen
14
- * Note: this might significantly increase the bandwidth consumed by people
15
- * streaming on high definition screens.
16
- */
17
- pixelDensity?: number | 'screen';
18
- };
1
+ import type LocalAudioTrack from './LocalAudioTrack';
2
+ import type LocalVideoTrack from './LocalVideoTrack';
3
+ import type RemoteAudioTrack from './RemoteAudioTrack';
4
+ import type RemoteVideoTrack from './RemoteVideoTrack';
5
+ export declare type RemoteTrack = RemoteAudioTrack | RemoteVideoTrack;
6
+ export declare type AudioTrack = RemoteAudioTrack | LocalAudioTrack;
7
+ export declare type VideoTrack = RemoteVideoTrack | LocalVideoTrack;
8
+ export declare type AdaptiveStreamSettings = {
9
+ /**
10
+ * Set a custom pixel density, defaults to 1
11
+ * When streaming videos on a ultra high definition screen this setting
12
+ * let's you account for the devicePixelRatio of those screens.
13
+ * Set it to `screen` to use the actual pixel density of the screen
14
+ * Note: this might significantly increase the bandwidth consumed by people
15
+ * streaming on high definition screens.
16
+ */
17
+ pixelDensity?: number | 'screen';
18
+ };
19
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/room/track/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,eAAe,MAAM,mBAAmB,CAAC;AACrD,OAAO,KAAK,eAAe,MAAM,mBAAmB,CAAC;AACrD,OAAO,KAAK,gBAAgB,MAAM,oBAAoB,CAAC;AACvD,OAAO,KAAK,gBAAgB,MAAM,oBAAoB,CAAC;AAEvD,oBAAY,WAAW,GAAG,gBAAgB,GAAG,gBAAgB,CAAC;AAC9D,oBAAY,UAAU,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAC5D,oBAAY,UAAU,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAE5D,oBAAY,sBAAsB,GAAG;IACnC;;;;;;;OAOG;IACH,YAAY,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;CAClC,CAAC"}
@@ -1,13 +1,14 @@
1
- import { AudioCaptureOptions, CreateLocalTracksOptions, VideoCaptureOptions } from './options';
2
- import { AudioTrack } from './types';
3
- export declare function mergeDefaultOptions(options?: CreateLocalTracksOptions, audioDefaults?: AudioCaptureOptions, videoDefaults?: VideoCaptureOptions): CreateLocalTracksOptions;
4
- export declare function constraintsForOptions(options: CreateLocalTracksOptions): MediaStreamConstraints;
5
- /**
6
- * This function detects silence on a given [[Track]] instance.
7
- * Returns true if the track seems to be entirely silent.
8
- */
9
- export declare function detectSilence(track: AudioTrack, timeOffset?: number): Promise<boolean>;
10
- /**
11
- * @internal
12
- */
13
- export declare function getNewAudioContext(): AudioContext | void;
1
+ import { AudioCaptureOptions, CreateLocalTracksOptions, VideoCaptureOptions } from './options';
2
+ import { AudioTrack } from './types';
3
+ export declare function mergeDefaultOptions(options?: CreateLocalTracksOptions, audioDefaults?: AudioCaptureOptions, videoDefaults?: VideoCaptureOptions): CreateLocalTracksOptions;
4
+ export declare function constraintsForOptions(options: CreateLocalTracksOptions): MediaStreamConstraints;
5
+ /**
6
+ * This function detects silence on a given [[Track]] instance.
7
+ * Returns true if the track seems to be entirely silent.
8
+ */
9
+ export declare function detectSilence(track: AudioTrack, timeOffset?: number): Promise<boolean>;
10
+ /**
11
+ * @internal
12
+ */
13
+ export declare function getNewAudioContext(): AudioContext | void;
14
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/room/track/utils.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAC/F,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,wBAAgB,mBAAmB,CACjC,OAAO,CAAC,EAAE,wBAAwB,EAClC,aAAa,CAAC,EAAE,mBAAmB,EACnC,aAAa,CAAC,EAAE,mBAAmB,GAClC,wBAAwB,CAqB1B;AAYD,wBAAgB,qBAAqB,CAAC,OAAO,EAAE,wBAAwB,GAAG,sBAAsB,CAqC/F;AACD;;;GAGG;AACH,wBAAsB,aAAa,CAAC,KAAK,EAAE,UAAU,EAAE,UAAU,SAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAkBzF;AAED;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,YAAY,GAAG,IAAI,CAMxD"}
@@ -1,16 +1,17 @@
1
- import { ClientInfo } from '../proto/livekit_models';
2
- export declare function unpackStreamId(packed: string): string[];
3
- export declare function sleep(duration: number): Promise<void>;
4
- export declare function isFireFox(): boolean;
5
- export declare function isSafari(): boolean;
6
- export declare function isMobile(): boolean;
7
- export declare function isWeb(): boolean;
8
- export declare const getResizeObserver: () => ResizeObserver;
9
- export declare const getIntersectionObserver: () => IntersectionObserver;
10
- export interface ObservableMediaElement extends HTMLMediaElement {
11
- handleResize: (entry: ResizeObserverEntry) => void;
12
- handleVisibilityChanged: (entry: IntersectionObserverEntry) => void;
13
- }
14
- export declare function getClientInfo(): ClientInfo;
15
- export declare function getEmptyVideoStreamTrack(): MediaStreamTrack;
16
- export declare function getEmptyAudioStreamTrack(): MediaStreamTrack;
1
+ import { ClientInfo } from '../proto/livekit_models';
2
+ export declare function unpackStreamId(packed: string): string[];
3
+ export declare function sleep(duration: number): Promise<void>;
4
+ export declare function isFireFox(): boolean;
5
+ export declare function isSafari(): boolean;
6
+ export declare function isMobile(): boolean;
7
+ export declare function isWeb(): boolean;
8
+ export declare const getResizeObserver: () => ResizeObserver;
9
+ export declare const getIntersectionObserver: () => IntersectionObserver;
10
+ export interface ObservableMediaElement extends HTMLMediaElement {
11
+ handleResize: (entry: ResizeObserverEntry) => void;
12
+ handleVisibilityChanged: (entry: IntersectionObserverEntry) => void;
13
+ }
14
+ export declare function getClientInfo(): ClientInfo;
15
+ export declare function getEmptyVideoStreamTrack(): MediaStreamTrack;
16
+ export declare function getEmptyAudioStreamTrack(): MediaStreamTrack;
17
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/room/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAkB,MAAM,yBAAyB,CAAC;AAKrE,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAMvD;AAED,wBAAsB,KAAK,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAE3D;AAED,wBAAgB,SAAS,IAAI,OAAO,CAGnC;AAED,wBAAgB,QAAQ,IAAI,OAAO,CAGlC;AAED,wBAAgB,QAAQ,IAAI,OAAO,CAGlC;AAED,wBAAgB,KAAK,IAAI,OAAO,CAE/B;AAeD,eAAO,MAAM,iBAAiB,sBAG7B,CAAC;AAGF,eAAO,MAAM,uBAAuB,4BAOnC,CAAC;AAEF,MAAM,WAAW,sBAAuB,SAAQ,gBAAgB;IAC9D,YAAY,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,IAAI,CAAC;IACnD,uBAAuB,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;CACrE;AAED,wBAAgB,aAAa,IAAI,UAAU,CAO1C;AAID,wBAAgB,wBAAwB,qBAevC;AAID,wBAAgB,wBAAwB,qBAevC"}
@@ -1,11 +1,12 @@
1
- /// <reference types="jest" />
2
- import { SignalClient } from '../api/SignalClient';
3
- import RTCEngine from '../room/RTCEngine';
4
- declare const mocks: {
5
- SignalClient: jest.MockedClass<typeof SignalClient>;
6
- RTCEngine: jest.MockedClass<typeof RTCEngine>;
7
- MockLocalVideoTrack: {
8
- stop: jest.Mock<any, any>;
9
- };
10
- };
11
- export default mocks;
1
+ /// <reference types="jest" />
2
+ import { SignalClient } from '../api/SignalClient';
3
+ import RTCEngine from '../room/RTCEngine';
4
+ declare const mocks: {
5
+ SignalClient: jest.MockedClass<typeof SignalClient>;
6
+ RTCEngine: jest.MockedClass<typeof RTCEngine>;
7
+ MockLocalVideoTrack: {
8
+ stop: jest.Mock<any, any>;
9
+ };
10
+ };
11
+ export default mocks;
12
+ //# sourceMappingURL=mocks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mocks.d.ts","sourceRoot":"","sources":["../../src/test/mocks.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,SAAS,MAAM,mBAAmB,CAAC;AAO1C,QAAA,MAAM,KAAK;;;;;;CAMV,CAAC;AAEF,eAAe,KAAK,CAAC"}
package/dist/version.d.ts CHANGED
@@ -1,2 +1,3 @@
1
- export declare const version = "0.18.4";
2
- export declare const protocolVersion = 7;
1
+ export declare const version = "0.18.6";
2
+ export declare const protocolVersion = 7;
3
+ //# sourceMappingURL=version.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,WAAW,CAAC;AAChC,eAAO,MAAM,eAAe,IAAI,CAAC"}