trtc-sdk-v5 5.8.0 → 5.8.1-beta.10
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/index.d.ts +2003 -1751
- package/package.json +1 -1
- package/plugins/cdn-streaming/package.json +1 -1
- package/plugins/cross-room/cross-room.esm.js +1 -1
- package/plugins/cross-room/cross-room.iife.js +1 -1
- package/plugins/cross-room/package.json +1 -1
- package/plugins/debug/debug.esm.js +26 -26
- package/plugins/debug/debug.iife.js +26 -26
- package/plugins/debug/package.json +1 -1
- package/plugins/device-detector/device-detector.esm.d.ts +18 -2
- package/plugins/device-detector/device-detector.esm.js +57 -57
- package/plugins/device-detector/device-detector.iife.js +57 -57
- package/plugins/device-detector/package.json +1 -1
- package/plugins/video-effect/basic-beauty/basic-beauty.esm.js +2 -2
- package/plugins/video-effect/basic-beauty/basic-beauty.iife.js +2 -2
- package/plugins/video-effect/basic-beauty/package.json +1 -1
- package/plugins/video-effect/beauty/package.json +1 -1
- package/plugins/video-effect/virtual-background/package.json +1 -1
- package/plugins/video-effect/virtual-background/virtual-background.esm.js +14 -14
- package/plugins/video-effect/virtual-background/virtual-background.iife.js +14 -14
- package/plugins/video-effect/watermark/package.json +1 -1
- package/plugins/video-effect/watermark/watermark.esm.js +1 -1
- package/plugins/video-effect/watermark/watermark.iife.js +1 -1
- package/trtc.esm.js +33 -30
- package/trtc.js +1 -1
- package/core.d.ts +0 -348
- package/plugins/cdn-streaming/cdn-streaming.js +0 -1
package/core.d.ts
DELETED
|
@@ -1,348 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
declare enum LOG_LEVEL {
|
|
3
|
-
/**
|
|
4
|
-
* 输出所有日志
|
|
5
|
-
*/
|
|
6
|
-
TRACE = 0,
|
|
7
|
-
/**
|
|
8
|
-
* 输出 DEBUG、INFO、WARN、ERROR 等级日志
|
|
9
|
-
*/
|
|
10
|
-
DEBUG = 1,
|
|
11
|
-
/**
|
|
12
|
-
* 输出 INFO、WARN、ERROR 等级日志
|
|
13
|
-
*/
|
|
14
|
-
INFO = 2,
|
|
15
|
-
/**
|
|
16
|
-
* 输出 WARN、ERROR 等级日志
|
|
17
|
-
*/
|
|
18
|
-
WARN = 3,
|
|
19
|
-
/**
|
|
20
|
-
* 输出 ERROR 等级日志
|
|
21
|
-
*/
|
|
22
|
-
ERROR = 4,
|
|
23
|
-
/**
|
|
24
|
-
* 不输出任何日志
|
|
25
|
-
*/
|
|
26
|
-
NONE = 5
|
|
27
|
-
}
|
|
28
|
-
declare const audioProfileMap: {
|
|
29
|
-
readonly standard: {
|
|
30
|
-
readonly sampleRate: 48000;
|
|
31
|
-
readonly channelCount: 1;
|
|
32
|
-
readonly bitrate: 40;
|
|
33
|
-
};
|
|
34
|
-
readonly 'standard-stereo': {
|
|
35
|
-
readonly sampleRate: 48000;
|
|
36
|
-
readonly channelCount: 2;
|
|
37
|
-
readonly bitrate: 64;
|
|
38
|
-
};
|
|
39
|
-
readonly high: {
|
|
40
|
-
readonly sampleRate: 48000;
|
|
41
|
-
readonly channelCount: 1;
|
|
42
|
-
readonly bitrate: 192;
|
|
43
|
-
};
|
|
44
|
-
readonly 'high-stereo': {
|
|
45
|
-
readonly sampleRate: 48000;
|
|
46
|
-
readonly channelCount: 2;
|
|
47
|
-
readonly bitrate: 192;
|
|
48
|
-
};
|
|
49
|
-
};
|
|
50
|
-
declare const videoProfileMap: {
|
|
51
|
-
readonly '120p': {
|
|
52
|
-
readonly width: 160;
|
|
53
|
-
readonly height: 120;
|
|
54
|
-
readonly frameRate: 15;
|
|
55
|
-
readonly bitrate: 200;
|
|
56
|
-
};
|
|
57
|
-
readonly '180p': {
|
|
58
|
-
readonly width: 320;
|
|
59
|
-
readonly height: 180;
|
|
60
|
-
readonly frameRate: 15;
|
|
61
|
-
readonly bitrate: 350;
|
|
62
|
-
};
|
|
63
|
-
readonly '240p': {
|
|
64
|
-
readonly width: 320;
|
|
65
|
-
readonly height: 240;
|
|
66
|
-
readonly frameRate: 15;
|
|
67
|
-
readonly bitrate: 400;
|
|
68
|
-
};
|
|
69
|
-
readonly '360p': {
|
|
70
|
-
readonly width: 640;
|
|
71
|
-
readonly height: 360;
|
|
72
|
-
readonly frameRate: 15;
|
|
73
|
-
readonly bitrate: 800;
|
|
74
|
-
};
|
|
75
|
-
readonly '480p': {
|
|
76
|
-
readonly width: 640;
|
|
77
|
-
readonly height: 480;
|
|
78
|
-
readonly frameRate: 15;
|
|
79
|
-
readonly bitrate: 900;
|
|
80
|
-
};
|
|
81
|
-
readonly '720p': {
|
|
82
|
-
readonly width: 1280;
|
|
83
|
-
readonly height: 720;
|
|
84
|
-
readonly frameRate: 15;
|
|
85
|
-
readonly bitrate: 1500;
|
|
86
|
-
};
|
|
87
|
-
readonly '1080p': {
|
|
88
|
-
readonly width: 1920;
|
|
89
|
-
readonly height: 1080;
|
|
90
|
-
readonly frameRate: 15;
|
|
91
|
-
readonly bitrate: 2000;
|
|
92
|
-
};
|
|
93
|
-
readonly '1440p': {
|
|
94
|
-
readonly width: 2560;
|
|
95
|
-
readonly height: 1440;
|
|
96
|
-
readonly frameRate: 30;
|
|
97
|
-
readonly bitrate: 4860;
|
|
98
|
-
};
|
|
99
|
-
readonly '4K': {
|
|
100
|
-
readonly width: 3840;
|
|
101
|
-
readonly height: 2160;
|
|
102
|
-
readonly frameRate: 30;
|
|
103
|
-
readonly bitrate: 9000;
|
|
104
|
-
};
|
|
105
|
-
};
|
|
106
|
-
declare const screenProfileMap: {
|
|
107
|
-
readonly '480p': {
|
|
108
|
-
readonly width: 640;
|
|
109
|
-
readonly height: 480;
|
|
110
|
-
readonly frameRate: 5;
|
|
111
|
-
readonly bitrate: 900;
|
|
112
|
-
};
|
|
113
|
-
readonly '480p_2': {
|
|
114
|
-
readonly width: 640;
|
|
115
|
-
readonly height: 480;
|
|
116
|
-
readonly frameRate: 30;
|
|
117
|
-
readonly bitrate: 1000;
|
|
118
|
-
};
|
|
119
|
-
readonly '720p': {
|
|
120
|
-
readonly width: 1280;
|
|
121
|
-
readonly height: 720;
|
|
122
|
-
readonly frameRate: 5;
|
|
123
|
-
readonly bitrate: 1200;
|
|
124
|
-
};
|
|
125
|
-
readonly '720p_2': {
|
|
126
|
-
readonly width: 1280;
|
|
127
|
-
readonly height: 720;
|
|
128
|
-
readonly frameRate: 30;
|
|
129
|
-
readonly bitrate: 3000;
|
|
130
|
-
};
|
|
131
|
-
readonly '1080p': {
|
|
132
|
-
readonly width: 1920;
|
|
133
|
-
readonly height: 1080;
|
|
134
|
-
readonly frameRate: 5;
|
|
135
|
-
readonly bitrate: 1600;
|
|
136
|
-
};
|
|
137
|
-
readonly '1080p_2': {
|
|
138
|
-
readonly width: 1920;
|
|
139
|
-
readonly height: 1080;
|
|
140
|
-
readonly frameRate: 30;
|
|
141
|
-
readonly bitrate: 4000;
|
|
142
|
-
};
|
|
143
|
-
};
|
|
144
|
-
declare const enum Scene {
|
|
145
|
-
LIVE = "live",
|
|
146
|
-
RTC = "rtc"
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
declare interface DeviceInfo {
|
|
163
|
-
readonly deviceId: string;
|
|
164
|
-
readonly groupId: string;
|
|
165
|
-
readonly kind: MediaDeviceKind;
|
|
166
|
-
readonly label: string;
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
declare const enum NetworkQualityValue {
|
|
204
|
-
UNKNOWN,
|
|
205
|
-
EXCELLENT,
|
|
206
|
-
GOOD,
|
|
207
|
-
POOR,
|
|
208
|
-
BAD,
|
|
209
|
-
VERY_BAD,
|
|
210
|
-
DISCONNECTED
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
declare const enum RemoteStreamType {
|
|
214
|
-
Main = 'main',
|
|
215
|
-
Aux = 'auxiliary',
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
declare interface MixTranscodeConfig {
|
|
219
|
-
/** Stream mixing mode */
|
|
220
|
-
mode?: 'manual' | 'preset-layout';
|
|
221
|
-
/** Stream ID after mixtranscoding. Default value: '' */
|
|
222
|
-
streamId?: string;
|
|
223
|
-
/**
|
|
224
|
-
* Width of the video resolution in px after transcoding. Default value: 640.
|
|
225
|
-
*
|
|
226
|
-
* The value must be greater than or equal to 0 and is large enough so that all mixed video streams can be accommodated.
|
|
227
|
-
*/
|
|
228
|
-
videoWidth?: number;
|
|
229
|
-
/**
|
|
230
|
-
* Height of the video resolution in px after transcoding. Default value: 480.
|
|
231
|
-
*
|
|
232
|
-
* The value must be greater than or equal to 0 and is large enough so that all mixed video streams can be accommodated.
|
|
233
|
-
*/
|
|
234
|
-
videoHeight?: number;
|
|
235
|
-
/** Video bitrate (Kbps) after transcoding. If `0` is passed in, the bitrate value is determined by `videoWidth` and `videoHeight`. */
|
|
236
|
-
videoBitrate?: number;
|
|
237
|
-
/** Video frame rate (fps) after transcoding. Default value: 15. Value range: (0, 30]. */
|
|
238
|
-
videoFramerate?: number;
|
|
239
|
-
/** Video keyframe interval (s) after transcoding. Default value: 2. Value range: [1, 8]. */
|
|
240
|
-
videoGOP?: number;
|
|
241
|
-
/** Audio sample rate (Hz) after transcoding. Default value: 48000 */
|
|
242
|
-
audioSampleRate?: number;
|
|
243
|
-
/** Audio bitrate (Kbps) after transcoding. Default value: 64. Value range: [32, 192]. */
|
|
244
|
-
audioBitrate?: number;
|
|
245
|
-
/** Number of sound channels after transcoding. Valid values: 1 (default), 2 */
|
|
246
|
-
audioChannels?: 1 | 2;
|
|
247
|
-
/** Background color of the image after mixing. The value must be a hexadecimal number. Default value: 0x000000 (black) */
|
|
248
|
-
backgroundColor?: number;
|
|
249
|
-
/** Background picture of the image after mixing. Default value: '' */
|
|
250
|
-
backgroundImage?: string;
|
|
251
|
-
/** Information list of users' streams mixed. The list must contain API caller information. */
|
|
252
|
-
mixUsers: MixUser[];
|
|
253
|
-
}
|
|
254
|
-
/**
|
|
255
|
-
* @link https://web.sdk.qcloud.com/trtc/webrtc/doc/en/global.html#MixUser
|
|
256
|
-
*/
|
|
257
|
-
declare interface MixUser {
|
|
258
|
-
/** userId */
|
|
259
|
-
userId: string;
|
|
260
|
-
/**
|
|
261
|
-
* user's roomId. You can use this param to mix streams from diffrent rooms.
|
|
262
|
-
* @since 4.11.5
|
|
263
|
-
*/
|
|
264
|
-
roomId: number | string;
|
|
265
|
-
/** Only the user's audio stream is mixed in. If the value is `true`, the following video parameters do not need to be passed in. */
|
|
266
|
-
pureAudio: boolean;
|
|
267
|
-
/** Width (px) of the user's stream in the mixed stream. The value must be greater than or equal to 0. The default value is 0. */
|
|
268
|
-
width?: number;
|
|
269
|
-
/** Height (px) of the user's stream in the mixed stream. The value must be greater than or equal to 0. The default value is 0. */
|
|
270
|
-
height?: number;
|
|
271
|
-
/** X coordinate (px) of the user's stream in the mixed stream, starting from the upper left corner of the mixed stream. The value must be greater than or equal to 0. The default value is 0. */
|
|
272
|
-
locationX?: number;
|
|
273
|
-
/** Y coordinate (px) of the user's stream in the mixed stream, starting from the upper left corner of the mixed stream. The value must be greater than or equal to 0. The default value is 0. */
|
|
274
|
-
locationY?: number;
|
|
275
|
-
/** Layer number of the user's stream in the mixed stream. The value range is [1, 15]. If `pureAudio` is `false`, `zOrder` must be passed in. */
|
|
276
|
-
zOrder?: number;
|
|
277
|
-
/** Remote stream type in manual mode. This parameter does not need to be set in preset layout mode. Valid values: `main` (primary stream), `auxiliary` (substream of screen sharing) */
|
|
278
|
-
streamType?: RemoteStreamType;
|
|
279
|
-
renderMode?: 0 | 1 | 2;
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
declare interface PublishCDNStreamOptions {
|
|
283
|
-
/** Custom stream ID. Default value: ${sdkAppId}_${roomId}_${userId}_main */
|
|
284
|
-
streamId?: string;
|
|
285
|
-
streamType?: RemoteStreamType;
|
|
286
|
-
/** Tencent Cloud live streaming `appId` */
|
|
287
|
-
appId?: number;
|
|
288
|
-
/** Tencent Cloud live streaming `bizId` */
|
|
289
|
-
bizId?: number;
|
|
290
|
-
/** Specified CDN address for stream publishing */
|
|
291
|
-
url?: string;
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
declare const enum PlayerState {
|
|
295
|
-
PAUSED = "PAUSED",
|
|
296
|
-
PLAYING = "PLAYING",
|
|
297
|
-
STOPPED = "STOPPED"
|
|
298
|
-
}
|
|
299
|
-
declare const enum UserRole {
|
|
300
|
-
ANCHOR = "anchor",
|
|
301
|
-
AUDIENCE = "audience"
|
|
302
|
-
}
|
|
303
|
-
declare const enum ConnectionState {
|
|
304
|
-
CONNECTED = "CONNECTED",
|
|
305
|
-
DISCONNECTED = "DISCONNECTED",
|
|
306
|
-
CONNECTING = "CONNECTING",
|
|
307
|
-
RECONNECTED = "RECONNECTED",
|
|
308
|
-
RECONNECTING = "RECONNECTING"
|
|
309
|
-
}
|
|
310
|
-
declare interface NetworkQuality {
|
|
311
|
-
uplinkNetworkQuality: NetworkQualityValue;
|
|
312
|
-
downlinkNetworkQuality: NetworkQualityValue;
|
|
313
|
-
uplinkRTT: number;
|
|
314
|
-
uplinkLoss: number;
|
|
315
|
-
downlinkRTT: number;
|
|
316
|
-
downlinkLoss: number;
|
|
317
|
-
downlinkInfo: {
|
|
318
|
-
rtt: number;
|
|
319
|
-
loss: number;
|
|
320
|
-
userId: string;
|
|
321
|
-
}[];
|
|
322
|
-
}
|
|
323
|
-
declare const enum BannedReason {
|
|
324
|
-
BANNED = "banned",
|
|
325
|
-
KICK = "kick",
|
|
326
|
-
USER_TIME_OUT = "user_time_out",
|
|
327
|
-
ROOM_DISBAND = "room_disband"
|
|
328
|
-
}
|
|
329
|
-
declare interface AudioSourceOptions {
|
|
330
|
-
id: string;
|
|
331
|
-
url: string;
|
|
332
|
-
loop?: boolean;
|
|
333
|
-
volume?: number;
|
|
334
|
-
operation?: string;
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var global,factory;global=this,factory=function(e){var t,r,i,o,s,a=Object.create,n=Object.defineProperty,d=Object.defineProperties,c=Object.getOwnPropertyDescriptor,h=Object.getOwnPropertyDescriptors,l=Object.getOwnPropertyNames,u=Object.getOwnPropertySymbols,m=Object.getPrototypeOf,p=Object.prototype.hasOwnProperty,g=Object.prototype.propertyIsEnumerable,b=(e,t,r)=>t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,f=(e,t)=>{for(var r in t||(t={}))p.call(t,r)&&b(e,r,t[r]);if(u)for(var r of u(t))g.call(t,r)&&b(e,r,t[r]);return e},_=(e,t,r)=>(r=null!=e?a(m(e)):{},((e,t,r,i)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let o of l(t))!p.call(e,o)&&o!==r&&n(e,o,{get:()=>t[o],enumerable:!(i=c(t,o))||i.enumerable});return e})(!t&&e&&e.__esModule?r:n(r,"default",{value:e,enumerable:!0}),e)),C=(e,t,r)=>(b(e,"symbol"!=typeof t?t+"":t,r),r),D=(t=(e,t)=>{!function(e){function r(e,t){var r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function i(e,t,i,o,s,a){return r(function(e,t){return e<<t|e>>>32-t}(r(r(t,e),r(o,a)),s),i)}function o(e,t,r,o,s,a,n){return i(t&r|~t&o,e,t,s,a,n)}function s(e,t,r,o,s,a,n){return i(t&o|r&~o,e,t,s,a,n)}function a(e,t,r,o,s,a,n){return i(t^r^o,e,t,s,a,n)}function n(e,t,r,o,s,a,n){return i(r^(t|~o),e,t,s,a,n)}function d(e,t){e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;var i,d,c,h,l,u=1732584193,m=-271733879,p=-1732584194,g=271733878;for(i=0;i<e.length;i+=16)d=u,c=m,h=p,l=g,u=o(u,m,p,g,e[i],7,-680876936),g=o(g,u,m,p,e[i+1],12,-389564586),p=o(p,g,u,m,e[i+2],17,606105819),m=o(m,p,g,u,e[i+3],22,-1044525330),u=o(u,m,p,g,e[i+4],7,-176418897),g=o(g,u,m,p,e[i+5],12,1200080426),p=o(p,g,u,m,e[i+6],17,-1473231341),m=o(m,p,g,u,e[i+7],22,-45705983),u=o(u,m,p,g,e[i+8],7,1770035416),g=o(g,u,m,p,e[i+9],12,-1958414417),p=o(p,g,u,m,e[i+10],17,-42063),m=o(m,p,g,u,e[i+11],22,-1990404162),u=o(u,m,p,g,e[i+12],7,1804603682),g=o(g,u,m,p,e[i+13],12,-40341101),p=o(p,g,u,m,e[i+14],17,-1502002290),u=s(u,m=o(m,p,g,u,e[i+15],22,1236535329),p,g,e[i+1],5,-165796510),g=s(g,u,m,p,e[i+6],9,-1069501632),p=s(p,g,u,m,e[i+11],14,643717713),m=s(m,p,g,u,e[i],20,-373897302),u=s(u,m,p,g,e[i+5],5,-701558691),g=s(g,u,m,p,e[i+10],9,38016083),p=s(p,g,u,m,e[i+15],14,-660478335),m=s(m,p,g,u,e[i+4],20,-405537848),u=s(u,m,p,g,e[i+9],5,568446438),g=s(g,u,m,p,e[i+14],9,-1019803690),p=s(p,g,u,m,e[i+3],14,-187363961),m=s(m,p,g,u,e[i+8],20,1163531501),u=s(u,m,p,g,e[i+13],5,-1444681467),g=s(g,u,m,p,e[i+2],9,-51403784),p=s(p,g,u,m,e[i+7],14,1735328473),u=a(u,m=s(m,p,g,u,e[i+12],20,-1926607734),p,g,e[i+5],4,-378558),g=a(g,u,m,p,e[i+8],11,-2022574463),p=a(p,g,u,m,e[i+11],16,1839030562),m=a(m,p,g,u,e[i+14],23,-35309556),u=a(u,m,p,g,e[i+1],4,-1530992060),g=a(g,u,m,p,e[i+4],11,1272893353),p=a(p,g,u,m,e[i+7],16,-155497632),m=a(m,p,g,u,e[i+10],23,-1094730640),u=a(u,m,p,g,e[i+13],4,681279174),g=a(g,u,m,p,e[i],11,-358537222),p=a(p,g,u,m,e[i+3],16,-722521979),m=a(m,p,g,u,e[i+6],23,76029189),u=a(u,m,p,g,e[i+9],4,-640364487),g=a(g,u,m,p,e[i+12],11,-421815835),p=a(p,g,u,m,e[i+15],16,530742520),u=n(u,m=a(m,p,g,u,e[i+2],23,-995338651),p,g,e[i],6,-198630844),g=n(g,u,m,p,e[i+7],10,1126891415),p=n(p,g,u,m,e[i+14],15,-1416354905),m=n(m,p,g,u,e[i+5],21,-57434055),u=n(u,m,p,g,e[i+12],6,1700485571),g=n(g,u,m,p,e[i+3],10,-1894986606),p=n(p,g,u,m,e[i+10],15,-1051523),m=n(m,p,g,u,e[i+1],21,-2054922799),u=n(u,m,p,g,e[i+8],6,1873313359),g=n(g,u,m,p,e[i+15],10,-30611744),p=n(p,g,u,m,e[i+6],15,-1560198380),m=n(m,p,g,u,e[i+13],21,1309151649),u=n(u,m,p,g,e[i+4],6,-145523070),g=n(g,u,m,p,e[i+11],10,-1120210379),p=n(p,g,u,m,e[i+2],15,718787259),m=n(m,p,g,u,e[i+9],21,-343485551),u=r(u,d),m=r(m,c),p=r(p,h),g=r(g,l);return[u,m,p,g]}function c(e){var t,r="",i=32*e.length;for(t=0;t<i;t+=8)r+=String.fromCharCode(e[t>>5]>>>t%32&255);return r}function h(e){var t,r=[];for(r[(e.length>>2)-1]=void 0,t=0;t<r.length;t+=1)r[t]=0;var i=8*e.length;for(t=0;t<i;t+=8)r[t>>5]|=(255&e.charCodeAt(t/8))<<t%32;return r}function l(e){var t,r,i="0123456789abcdef",o="";for(r=0;r<e.length;r+=1)t=e.charCodeAt(r),o+=i.charAt(t>>>4&15)+i.charAt(15&t);return o}function u(e){return unescape(encodeURIComponent(e))}function m(e){return function(e){return c(d(h(e),8*e.length))}(u(e))}function p(e,t){return function(e,t){var r,i,o=h(e),s=[],a=[];for(s[15]=a[15]=void 0,o.length>16&&(o=d(o,8*e.length)),r=0;r<16;r+=1)s[r]=909522486^o[r],a[r]=1549556828^o[r];return i=d(s.concat(h(t)),512+8*t.length),c(d(a.concat(i),640))}(u(e),u(t))}function g(e,t,r){return t?r?p(t,e):function(e,t){return l(p(e,t))}(t,e):r?m(e):function(e){return l(m(e))}(e)}"function"==typeof define&&define.amd?define((function(){return g})):"object"==typeof t&&t.exports?t.exports=g:e.md5=g}(e)},()=>(r||t((r={exports:{}}).exports,r),r.exports)),N=_(D(),1),I=((o=I||{}).PublishMainStreamToCDN="publish-main-stream-to-cdn",o.PublishSubStreamToCDN="publish-sub-stream-to-cdn",o.PublishMixStreamToCDN="publish-mix-stream-to-cdn",o),v=((i=v||{}).Main="main",i.Sub="sub",i),S=0,y=4,T=5,M=class{constructor(e,t){C(this,"_core"),C(this,"_room"),C(this,"_log"),C(this,"_params"),C(this,"_publishGivenCDNData",null),this._core=e,this._room=e.room,this._log=t}get isPublishingGivenCDN(){return!!this._params}async startPublishGivenCDN(e){if(this._log.info("[CDNStreaming] startPublishGivenCDN() current: ".concat(JSON.stringify(this._params),", params: ").concat(JSON.stringify(e))),this.isPublishingGivenCDN){let{appId:t,bizId:r,url:i}=this._params||{};if(t===e.appId&&r===e.bizId&&i===e.url)return;await this.stopPublishGivenCDN()}this._params=e,this._publishGivenCDNData={pushRequestTime:Date.now(),pushAppId:e.appId,pushBizId:e.bizId,pushCdnUrl:e.url,pushStreamType:this.convertStreamType(null==e?void 0:e.publishMode),pushStreamId:e.streamId};try{let t=await this._room.sendStartPublishCDN(this._publishGivenCDNData,!1),{code:r,message:i}=t.data;if(0!==r)throw this.resetGivenCDN(),this._log.error("[CDNStreaming] server failed: start given cdn errCode: ".concat(r," errMsg: ").concat(i," options: ").concat(JSON.stringify(e))),new Error("[CDNStreaming] server failed: start given cdn errCode: ".concat(r," errMsg: ").concat(i));this._log.info("[CDNStreaming] server success: start given cdn.")}catch(i){throw this.resetGivenCDN(),i}}async stopPublishGivenCDN(){if(this._log.info("[CDNStreaming] stopPublishGivenCDN"),!this.isPublishingGivenCDN||!this._publishGivenCDNData)return void this.resetGivenCDN();let{pushAppId:e,pushBizId:t,pushCdnUrl:r,pushStreamType:i,pushStreamId:o}=this._publishGivenCDNData,s={pushRequestTime:Date.now(),pushAppId:e,pushBizId:t,pushCdnUrl:r,pushStreamType:i,pushStreamId:o},a=await this._room.sendStopPublishCDN(s,!1),{code:n,message:d}=a.data;if(0!==n)throw this._log.error("[CDNStreaming] server failed: stop given cdn errCode: ".concat(n," errMsg: ").concat(d," data: ").concat(JSON.stringify(s))),new Error("[CDNStreaming] server failed: stop given cdn errCode: ".concat(n," errMsg: ").concat(d));this._log.info("[CDNStreaming] server success: stop given cdn."),this.resetGivenCDN()}resetGivenCDN(){this._publishGivenCDNData=null,this._params=void 0}convertStreamType(e){return"publish-main-stream-to-cdn"===e?"main":"aux"}},P=class{constructor(e,t){C(this,"_core"),C(this,"_room"),C(this,"_log"),C(this,"_config",null),C(this,"_data",null),C(this,"_givenCDNManager"),this._core=e,this._room=e.room,this._log=t,this.reset()}get isMixing(){return!!this._data}get isStarted(){return!!this._config}get hasCustomCDN(){var e,t,r;return(null==(e=this._config)?void 0:e.target.appId)&&(null==(t=this._config)?void 0:t.target.bizId)&&(null==(r=this._config)?void 0:r.target.url)}async startMixTranscode(e){if(this._log.info("startMixTranscode: ".concat(JSON.stringify(e))),this._config=e,this.installEvents(),this._core.room.isJoined)try{let t=this.getInputParam(e),r=this.getOutputParam(e),i=this.getOutputSessionId({config:e,roomId:this._room.roomId,userId:this._room.userId});this.isMixing&&this._data&&i!==this._data.outputSessionId&&(this._log.info("[CDNStreaming] streamId changed, auto stop mixing before start"),await this.doStopMixTranscode()),await this.doStartMixTranscode({outputSessionId:i,inputParam:t,outputParam:r});let{appId:o,bizId:s,url:a,streamId:n=""}=e.target;o&&s&&a&&(this._givenCDNManager||(this._givenCDNManager=new M(this._core,this._log)),await this._givenCDNManager.startPublishGivenCDN({publishMode:e.target.publishMode,appId:o,bizId:s,url:a,streamId:n}))}catch(i){throw this.reset(),i}}async doStartMixTranscode(e){let{outputSessionId:t,inputParam:r,outputParam:i}=e,o={roomId:String(this._room.roomId),mcuRequestTime:Date.now(),outputSessionId:t,inputParam:r,outputParam:i};this._log.info("[CDNStreaming] doStartMixTranscode: ".concat(JSON.stringify(o)));let s=await this._room.sendStartMixTranscode(o),{code:a}=s.data,{message:n}=s.data;if(0!==a)throw-102083===a&&(n="Please enable relayed-push in ".concat(this._core.constants.CLOUD_CONSOLE_URL," and try later, refer to ").concat(this._core.constants.DOC_URL,"tutorial-26-advanced-publish-cdn-stream.html")),this._log.error("[CDNStreaming] server failed: start mix errCode: ".concat(a," errMsg: ").concat(n)),new Error("[CDNStreaming] server failed: start mix errCode: ".concat(a," errMsg: ").concat(n));this._log.info("[CDNStreaming] server success: start mix"),this._data=o}async stopMixTranscode(){this._log.info("[CDNStreaming] stopMixTranscode");try{this.isStarted&&this.isMixing&&(await this.doStopMixTranscode(),this._config&&this.hasCustomCDN&&this._givenCDNManager&&await this._givenCDNManager.stopPublishGivenCDN())}catch(r){throw r}this.reset()}async doStopMixTranscode(){let e={mcuRequestTime:Date.now(),outputSessionId:this._data.outputSessionId,streamType:this._data.outputParam.streamType};this._log.info("[CDNStreaming] doStopMixTranscode: ".concat(JSON.stringify(e)));let t=await this._room.sendStopMixTranscode(e),{code:r,message:i}=t.data;if(0!==r)throw this._log.error("[CDNStreaming] server failed: start mix errCode: ".concat(r," errMsg: ").concat(i)),new Error("[CDNStreaming] server failed: start mix errCode: ".concat(r," errMsg: ").concat(i));this._log.info("[CDNStreaming] server success: stop mix"),this.reset()}reset(){this._config=null,this._data=null,this.uninstallEvents()}installEvents(){this._core.room.on("joined",this.handleRoomJoined,this),this._core.room.on("left",this.handleRoomLeft,this)}uninstallEvents(){this._core.room.off("joined",this.handleRoomJoined,this),this._core.room.off("left",this.handleRoomLeft,this)}async handleRoomJoined(){this._log.info("[CDNStreaming] handleJoined: ".concat(JSON.stringify(this._config))),this.isStarted&&this._config&&await this.startMixTranscode(this._config)}async handleRoomLeft(){this._log.info("[CDNStreaming] handleRoomLeft: ".concat(JSON.stringify(this._config))),this._data=null}getOutputSessionId(e){let{config:t,userId:r,roomId:i}=e;return this._core.utils.isString(t.target.streamId)&&t.target.streamId.length>0?t.target.streamId:(0,N.default)("".concat(i,"_").concat(r,"_main"))}getStringRoomId(e,t){return e?String(e):t}getInputParam(e){let{mix:t={}}=e,{audioMixUserList:r=[],videoLayoutList:i=[]}=t,o=i.map((e=>({userId:e.fixedVideoUser.userId,roomId:this.getStringRoomId(e.fixedVideoUser.roomId,e.fixedVideoUser.strRoomId)||this._core.room.roomId,width:e.width||0,height:e.height||0,locationX:e.locationX||0,locationY:e.locationY||0,zOrder:e.zOrder||1,streamType:"sub"===e.fixedVideoStreamType?1:0,inputType:T,renderMode:e.fillMode||0})));return r.forEach((e=>{let t=o.findIndex((t=>t.userId===e.userId&&t.roomId===this.getStringRoomId(e.roomId,e.strRoomId)));-1!==t?o[t].inputType=S:o.push({userId:e.userId,roomId:e.roomId||e.strRoomId,inputType:y})})),o}getOutputParam(e){let t=e.target.streamId||"",{encoding:r={},mix:i={}}=e;return{streamId:t,streamType:t.length>0?1:0,width:this._core.utils.isUndefined(r.videoWidth)?640:r.videoWidth,height:this._core.utils.isUndefined(r.videoHeight)?480:r.videoHeight,videoBps:r.videoBitrate||0,fps:r.videoFramerate||15,gop:r.videoGOP||2,audioSampleRate:r.audioSampleRate||48e3,audioBps:r.audioBitrate||64,audioChannels:r.audioChannels||1,backgroundColor:i.backgroundColor||0,backgroundImg:i.backgroundImage||"",extraInfo:"",videoCodec:2,audioCodec:0}}},w=_(D(),1),E=class{constructor(e,t){C(this,"_room"),C(this,"_core"),C(this,"_log"),C(this,"_paramsForTencentCDN"),C(this,"_initParamsForTencentCDN",{isPublished:!1,isStarted:!1}),this._core=e,this._room=e.room,this._log=t,this._paramsForTencentCDN=new Map([["publish-main-stream-to-cdn",this._initParamsForTencentCDN],["publish-sub-stream-to-cdn",this._initParamsForTencentCDN]])}installEvents(){this._core.innerEmitter.on("104",this.handlePublished,this),this._core.room.on("left",this.handleRoomLeft,this)}uninstallEvents(){this._core.innerEmitter.off("104",this.handlePublished,this),this._core.room.off("left",this.handleRoomLeft,this)}async handlePublished(e){let{track:t}=e;var r;if(t.room!==this._room||(this._log.info("[CDNStreaming] handlePublished: mediaType ".concat(t.mediaType,", roomID ").concat(null==(r=null==t?void 0:t.room)?void 0:r.roomId,", ").concat(this._room.isMainStreamPublished)),1===t.mediaType))return;let i=4===t.mediaType?"publish-main-stream-to-cdn":"publish-sub-stream-to-cdn",o=this._paramsForTencentCDN.get(i)||null;null!=o&&o.target&&o.isStarted&&await this.startPublishTencentCDN(o.target)}async handleRoomLeft(){this._log.info("[CDNStreaming] handleRoomLeft"),this.changeDataStatus("publish-main-stream-to-cdn",{isPublished:!1}),this.changeDataStatus("publish-sub-stream-to-cdn",{isPublished:!1})}isStreamPublished(e){return"publish-main-stream-to-cdn"!==e||this._room.isMainStreamPublished?!("publish-sub-stream-to-cdn"===e&&!this._room.isAuxStreamPublished&&(this._log.info("[CDNStreaming] Sub has not already published, will auto reStart after published."),1)):(this._log.info("[CDNStreaming] Main stream has not already published, will auto reStart after published."),!1)}changeDataStatus(e,t){let r=this._paramsForTencentCDN.get(e),i=f(f({},r),t);this._paramsForTencentCDN.set(e,i)}async startPublishTencentCDN(e){if(this._log.info("[CDNStreaming] startPublishTencentCDN ".concat(JSON.stringify(e))),this.installEvents(),this.changeDataStatus(e.publishMode,{target:e,isStarted:!0}),!this.isStreamPublished(e.publishMode))return;let t=e.streamId||"",r=this.generatePublishCDNStreamId(t,e.publishMode),i=this.generatePublishCDNSessionId(e.publishMode),o="publish-sub-stream-to-cdn"===e.publishMode?1:0,s={requestTime:Date.now(),sessionId:i,streamId:r,streamType:o};await this.doStartPublishTencentCDN(s,e.publishMode);let{appId:a,bizId:n,url:d}=e;if(a&&n&&d){let t=this._paramsForTencentCDN.get(e.publishMode)||this._initParamsForTencentCDN;null!=t&&t.givenCDNManager||(t.givenCDNManager=new M(this._core,this._log),this._paramsForTencentCDN.set(e.publishMode,t)),await t.givenCDNManager.startPublishGivenCDN({publishMode:e.publishMode,appId:a,bizId:n,url:d,streamId:r})}}async doStartPublishTencentCDN(e,t){this._log.info("[CDNStreaming] doStartPublishTencentCDN: ".concat(JSON.stringify(e)));let r=0;for(;;){let i=await this._room.sendStartPublishCDN(e,!0),{code:o}=i.data,{message:s}=i.data;if(0===o){this._log.info("[CDNStreaming] server success: start tencent cdn"),this.changeDataStatus(t,{isPublished:!0});break}if(!(-10006===o&&r<6))throw this.changeDataStatus(t,{isPublished:!1}),-102083===o&&(s="Please enable relayed-push in ".concat(this._core.constants.CLOUD_CONSOLE_URL," and try later, refer to ").concat(this._core.constants.DOC_URL,"tutorial-26-advanced-publish-cdn-stream.html")),this._log.error("[CDNStreaming] server failed: start tencent cdn errCode: ".concat(o," errMsg: ").concat(s)),new Error("[CDNStreaming] server failed: start tencent cdn errCode: ".concat(o," errMsg: ").concat(s));this._log.warn("[CDNStreaming] doStartPublishTencentCDN: retry...".concat(r+1,"/6, reason: ").concat(s)),r+=1,await new Promise((e=>setTimeout(e,500)))}}async stopPublishTencentCDN(e){this._log.info("[CDNStreaming] doStartPublishTencentCDN: ".concat(JSON.stringify(e)));let t=this._paramsForTencentCDN.get(e)||this._initParamsForTencentCDN;if(t.isPublished){let{target:r}=t;null!=r&&r.bizId&&r.appId&&r.url&&null!=t&&t.givenCDNManager&&await(null==t?void 0:t.givenCDNManager.stopPublishGivenCDN()),await this.doStopPublishTencentCDN(e)}this._paramsForTencentCDN.set(e,this._initParamsForTencentCDN)}async doStopPublishTencentCDN(e){let t={requestTime:Date.now(),sessionId:(0,w.default)("".concat(this._room.roomId,"_").concat(this._room.userId,"_").concat(this.convertPublishModeToStreamType(e)))};this._log.info("[CDNStreaming] doStopPublishTencentCDN: ".concat(JSON.stringify(t)));let r=await this._room.sendStopPublishCDN(t,!0),{code:i}=r.data,{message:o}=r.data;if(0!==i)throw-102069===i&&(this._paramsForTencentCDN.set(e,this._initParamsForTencentCDN),o="can not stop in auto relayed-push mode ".concat(o)),this._log.error("[CDNStreaming] server failed: stop tencent cdn errCode: ".concat(i," errMsg: ").concat(o)),new Error("[CDNStreaming] server failed: stop tencent cdn errCode: ".concat(i," errMsg: ").concat(o));this._log.info("[CDNStreaming] server success: stop tencent cdn"),this._paramsForTencentCDN.set(e,this._initParamsForTencentCDN),this.reset(e)}reset(e){this.uninstallEvents(),this._paramsForTencentCDN.set(e,this._initParamsForTencentCDN)}generatePublishCDNStreamId(e,t){if(""===e){let e="".concat(this._room.roomId,"_").concat(this._room.userId,"_").concat(this.convertPublishModeToStreamType(t));return/^[A-Za-z\d_-]*$/.test(e)||(e=(0,w.default)(e)),"".concat(this._room.sdkAppId,"_").concat(e)}return e}convertPublishModeToStreamType(e){return"publish-main-stream-to-cdn"===e?"main":"aux"}generatePublishCDNSessionId(e){return(0,w.default)("".concat(this._room.roomId,"_").concat(this._room.userId,"_").concat(this.convertPublishModeToStreamType(e)))}},x={type:"number",notLessThanZero:!0},R={type:"object",required:!0,properties:{userId:{required:!0,type:"string"},roomId:{type:["string","number"],validate:function(e,t,r,i){let{RtcError:o,ErrorCode:a,ErrorCodeDictionary:n}=s;if((e=>"string"==typeof e)(e))throw new o({code:a.INVALID_PARAMETER,extraCode:n.INVALID_ROOM_ID_INTEGER_STRING,fnName:r,messageParams:{key:"roomId"}});if(void 0!==e&&!(/^[1-9]\d*$/.test(String(e))&&e<4294967295))throw new o({code:a.INVALID_PARAMETER,extraCode:n.INVALID_ROOM_ID_INTEGER,fnName:r,messageParams:{key:"roomId"}})}},strRoomId:{type:"string",validate:function(e,t,r,i){let{RtcError:o,ErrorCode:a,ErrorCodeDictionary:n}=s;if(!/^[A-Za-z\d\s!#$%&()+\-:;<=.>?@[\]^_{}|~,]{1,64}$/.test(e))throw new o({code:a.INVALID_PARAMETER,extraCode:n.INVALID_ROOM_ID_STRING,fnName:r,messageParams:{key:"strRoomId"}})}}}},O={required:!0,properties:{publishMode:{required:!0,values:["publish-main-stream-to-cdn","publish-mix-stream-to-cdn","publish-sub-stream-to-cdn"]},streamId:{required:!1,type:"string",validate:function(e,t,r,i){if(!/^[A-Za-z\d_-]*$/.test(e)){let{RtcError:e,ErrorCode:t,ErrorCodeDictionary:r}=s;throw new e({code:t.INVALID_PARAMETER,extraCode:r.INVALID_STREAM_ID,messageParams:{key:"streamId"}})}}},appId:{type:"number",allowEmpty:!1},bizId:{type:"number",allowEmpty:!1},url:{type:"string",allowEmpty:!1}}},A={required:!1,type:"object",properties:{videoWidth:x,videoHeight:x,videoBitrate:((e,t)=>d(e,h(t)))(f({},x),{allowEmpty:!1}),videoFramerate:{type:"number",validate(e,t,r,i){if(e<=0||e>30){let{RtcError:e,ErrorCode:t}=s;throw new e({code:t.INVALID_PARAMETER,message:"Invalid parameter mixConfig -> videoFramerate, the value must be between (0, 30]."})}}},videoGOP:{type:"number",validate(e,t,r,i){if(e<1||e>8){let{RtcError:e,ErrorCode:t}=s;throw new e({code:t.INVALID_PARAMETER,message:"Invalid parameter mixConfig -> videoGOP, the value must be between [1, 8]."})}}},audioSampleRate:x,audioBitrate:{type:"number",validate(e,t,r,i){if(e<32||e>192){let{RtcError:e,ErrorCode:t}=s;throw new e({code:t.INVALID_PARAMETER,message:"Invalid parameter mixConfig -> audioBitrate, the value must be between [32, 192]."})}}},audioChannels:{type:"number",values:[1,2]}}},L={required:!1,type:"object",properties:{backgroundColor:{type:"number"},backgroundImage:{type:"string"},audioMixUserList:{type:"array",arrayItem:f({},R)},videoLayoutList:{type:"array",required:!0,arrayItem:{type:"object",properties:{fixedVideoUser:f({},R),fixedVideoStreamType:{type:"string",required:!0,values:["main","sub"]},fillMode:{type:"number",values:[0,1,2,4]},zOrder:{type:"number",required:!0,validate(e,t,r,i){if(e<1||e>15){let{RtcError:e,ErrorCode:t}=s;throw new e({code:t.INVALID_PARAMETER,message:"Invalid parameter mix -> videoLayoutList -> zOrder, the value must be between [1, 15]."})}}},width:x,height:x,locationX:x,locationY:x}}}}},j=0,G=class{constructor(e){this.core=e,C(this,"_mixTranscodeManager"),C(this,"_publishCDNManager"),C(this,"_core"),C(this,"_modeOptions"),C(this,"seq"),C(this,"_log"),j+=1,this.seq=j,this._log=e.log.createChild({id:"".concat(this.getAlias()).concat(j)}),this._log.info("[CDNStreaming] created id=".concat(this.getAlias()).concat(j)),this._core=e,this._modeOptions=new Map,this._mixTranscodeManager=new P(e,this._log),this._publishCDNManager=new E(e,this._log)}getName(){return"CDNStreaming"}getAlias(){return"cdn"}getValidateRule(e){switch(e){case"start":return function(e){return s=e.errorModule,{name:"CDNStreamingOptions",type:"object",required:!0,allowEmpty:!1,properties:{target:f({},O),encoding:f({},A),mix:f({},L)},validate(t,r,i,o){var s,a;let{publishMode:n}=t.target,{encoding:d,mix:c}=t;if("publish-mix-stream-to-cdn"===n){let{RtcError:t,ErrorCode:r,ErrorCodeDictionary:o}=e.errorModule;if(!d)throw new t({code:r.INVALID_PARAMETER,extraCode:o.INVALID_PARAMETER_REQUIRED,fnName:i,messageParams:{key:"encoding"}});if(!c)throw new t({code:r.INVALID_PARAMETER,extraCode:o.INVALID_PARAMETER_REQUIRED,fnName:i,messageParams:{key:"mix"}});if(c&&c.videoLayoutList){let i=0,o=0,n=[];if(c.videoLayoutList.forEach(((e,t)=>{n.push(e.fixedVideoUser.userId),e.width+e.locationX>i&&(i=e.width+e.locationX),e.height+e.locationY>o&&(o=e.height+e.locationY)})),n.indexOf(e.room.userId)<0)throw new t({code:r.INVALID_PARAMETER,message:"Invalid parameter mix -> videoLayoutList, the value must be include self."});let h=null!=(s=null==d?void 0:d.videoWidth)?s:640,l=null!=(a=null==d?void 0:d.videoHeight)?a:480;if(h<i||l<o)throw new t({code:r.INVALID_PARAMETER,message:"Invalid parameter encoding, the width and height of the mixed video must encompass all the mixed-in video streams."})}}}}}(this._core);case"update":return function(e){return s=e.errorModule,{name:"CDNStreamingOptions",type:"object",required:!0,allowEmpty:!1,properties:{target:f({},O),encoding:f({},A),mix:f({},L)}}}(this._core);case"stop":return function(e){return s=e.errorModule,{name:"CDNStreamingOptions",type:"object",required:!0,allowEmpty:!1,properties:{target:{required:!0,properties:{publishMode:{required:!0,values:["publish-main-stream-to-cdn","publish-mix-stream-to-cdn","publish-sub-stream-to-cdn"]}}}}}}(this._core)}}getGroup(e){return e.target.publishMode}async start(e){return this._modeOptions.set(e.target.publishMode,e),await this.doStart(e)}async update(e){let t=this._modeOptions.get(e.target.publishMode);return this._core.utils.deepMerge(t,e),await this.doStart(t)}async stop(e){switch(e.target.publishMode){case"publish-mix-stream-to-cdn":await this._mixTranscodeManager.stopMixTranscode();break;case"publish-main-stream-to-cdn":case"publish-sub-stream-to-cdn":await this._publishCDNManager.stopPublishTencentCDN(e.target.publishMode)}this._modeOptions.delete(e.target.publishMode)}async doStart(e){switch(this._log.info("[CDNStreaming] doStart: ".concat(JSON.stringify(e))),e.target.publishMode){case"publish-mix-stream-to-cdn":await this._mixTranscodeManager.startMixTranscode(e);break;case"publish-main-stream-to-cdn":case"publish-sub-stream-to-cdn":await this._publishCDNManager.startPublishTencentCDN(e.target)}}};C(G,"TYPE",{PublishMode:{PublishMainStreamToCDN:"publish-main-stream-to-cdn",PublishSubStreamToCDN:"publish-sub-stream-to-cdn",PublishMixStreamToCDN:"publish-mix-stream-to-cdn"}});var q=G;e.CDNStreaming=G,e.PublishMode=I,e.TRTCStreamType=v,e.default=q,Object.defineProperty(e,"__esModule",{value:!0})},"object"==typeof exports&&"undefined"!=typeof module?factory(exports,require("core-js/modules/es.array.iterator.js"),require("core-js/modules/web.dom-collections.iterator.js"),require("core-js/modules/es.promise.js"),require("core-js/modules/web.dom-collections.for-each.js"),require("core-js/modules/es.regexp.exec.js")):"function"==typeof define&&define.amd?define(["exports","core-js/modules/es.array.iterator.js","core-js/modules/web.dom-collections.iterator.js","core-js/modules/es.promise.js","core-js/modules/web.dom-collections.for-each.js","core-js/modules/es.regexp.exec.js"],factory):factory((global="undefined"!=typeof globalThis?globalThis:global||self).CDNStreaming={});
|