@rongcloud/plugin-rtc 5.2.4 → 5.3.1
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/dist/index.d.ts +312 -13
- package/dist/index.esm.js +2 -2
- package/dist/index.js +1 -1
- package/dist/index.umd.js +1 -1
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* RCRTC - v5.
|
|
3
|
-
* CommitId -
|
|
4
|
-
* Fri Jan 28 2022 10:
|
|
2
|
+
* RCRTC - v5.3.1
|
|
3
|
+
* CommitId - e1af0f5ccb06a0084c94e1219d8af54c9793c06b
|
|
4
|
+
* Fri Jan 28 2022 10:45:10 GMT+0800 (China Standard Time)
|
|
5
5
|
* ©2020 RongCloud, Inc. All rights reserved.
|
|
6
6
|
*/
|
|
7
|
-
import { EventEmitter, LogLevel, RTCMode, IRuntime, RTCPluginContext, IServerRTCRoomEntry,
|
|
7
|
+
import { EventEmitter, LogLevel, RTCMode, IRuntime, RTCPluginContext, IServerRTCRoomEntry, IReceivedMessage, ErrorCode, IJoinRTCRoomData, KVString, RTCJoinType, IRTCJoinedInfo, IPluginGenerator } from '@rongcloud/engine';
|
|
8
8
|
export { RTCJoinType } from '@rongcloud/engine';
|
|
9
9
|
|
|
10
10
|
/**
|
|
@@ -84,7 +84,9 @@ declare enum RCRTCCode {
|
|
|
84
84
|
/** 加入 RTC 房间 joinTYype 为 1 时,当前有其他端在房间时的应答码 */
|
|
85
85
|
SIGNAL_JOIN_RTC_ROOM_REFUSED = 53028,
|
|
86
86
|
/** 设置音频输出设备时,无权限使用请求的设备 */
|
|
87
|
-
NO_PERMISSION_TO_USE_REQUESTED_DEVICE = 53029
|
|
87
|
+
NO_PERMISSION_TO_USE_REQUESTED_DEVICE = 53029,
|
|
88
|
+
/** 方法在 PK 房间上不可用 */
|
|
89
|
+
THE_FUNCTION_IS_DISABLED_IN_PKROOM = 53030
|
|
88
90
|
}
|
|
89
91
|
|
|
90
92
|
/**
|
|
@@ -910,6 +912,68 @@ interface IAudioLevelChangeHandler {
|
|
|
910
912
|
declare type RoomData = {
|
|
911
913
|
[userId: string]: IPublishedResource[];
|
|
912
914
|
};
|
|
915
|
+
/**
|
|
916
|
+
* 业务层发起连麦、响应连麦可选参数定义
|
|
917
|
+
*/
|
|
918
|
+
interface IReqResPKOptions {
|
|
919
|
+
autoMix?: boolean;
|
|
920
|
+
extra?: string;
|
|
921
|
+
}
|
|
922
|
+
interface IPKInviterBaseInfo {
|
|
923
|
+
/**
|
|
924
|
+
* 邀请者房间 ID
|
|
925
|
+
*/
|
|
926
|
+
inviterRoomId: string;
|
|
927
|
+
/**
|
|
928
|
+
* 邀请者用户 ID
|
|
929
|
+
*/
|
|
930
|
+
inviterUserId: string;
|
|
931
|
+
}
|
|
932
|
+
interface IPKInviteeBaseInfo {
|
|
933
|
+
/**
|
|
934
|
+
* 被邀请者房间 ID
|
|
935
|
+
*/
|
|
936
|
+
inviteeRoomId: string;
|
|
937
|
+
/**
|
|
938
|
+
* 被邀请者用户 ID
|
|
939
|
+
*/
|
|
940
|
+
inviteeUserId: string;
|
|
941
|
+
}
|
|
942
|
+
/**
|
|
943
|
+
* 业务层监听收到连麦邀请、取消连麦的字段
|
|
944
|
+
*/
|
|
945
|
+
interface IPKInviteInfo extends IPKInviterBaseInfo {
|
|
946
|
+
/**
|
|
947
|
+
* 邀请额外信息
|
|
948
|
+
*/
|
|
949
|
+
extra?: string;
|
|
950
|
+
}
|
|
951
|
+
/**
|
|
952
|
+
* 业务层监听收到连麦应答的字段
|
|
953
|
+
*/
|
|
954
|
+
interface IPKInviteAnswerInfo extends IPKInviterBaseInfo, IPKInviteeBaseInfo {
|
|
955
|
+
/**
|
|
956
|
+
* 是否同意邀请
|
|
957
|
+
*/
|
|
958
|
+
agree: boolean;
|
|
959
|
+
/**
|
|
960
|
+
* 响应额外信息
|
|
961
|
+
*/
|
|
962
|
+
extra?: string;
|
|
963
|
+
}
|
|
964
|
+
/**
|
|
965
|
+
* 业务层监听收到连麦结束的字段
|
|
966
|
+
*/
|
|
967
|
+
interface IPKEndInfo {
|
|
968
|
+
/**
|
|
969
|
+
* 发起结束的房间 ID
|
|
970
|
+
*/
|
|
971
|
+
endRoomId: string;
|
|
972
|
+
/**
|
|
973
|
+
* 发起结束的用户 ID
|
|
974
|
+
*/
|
|
975
|
+
endUserId: string;
|
|
976
|
+
}
|
|
913
977
|
/**
|
|
914
978
|
* 观众加房间返回给客户的 CDN 信息
|
|
915
979
|
*/
|
|
@@ -1007,7 +1071,7 @@ interface IExchangeReqBody {
|
|
|
1007
1071
|
/**
|
|
1008
1072
|
* 是否默认合流
|
|
1009
1073
|
*/
|
|
1010
|
-
|
|
1074
|
+
autoMix: boolean;
|
|
1011
1075
|
/**
|
|
1012
1076
|
* 房间 Id 对应的 SessionId
|
|
1013
1077
|
*/
|
|
@@ -2027,6 +2091,171 @@ declare class RCRTCPeerConnection extends EventEmitter {
|
|
|
2027
2091
|
clearReTryExchangeTimer(): void;
|
|
2028
2092
|
}
|
|
2029
2093
|
|
|
2094
|
+
declare type IOnRecvPKMsg = (msg: IReceivedMessage) => void;
|
|
2095
|
+
interface IRoomPKEventListener {
|
|
2096
|
+
/**
|
|
2097
|
+
* 收到连麦邀请
|
|
2098
|
+
*/
|
|
2099
|
+
onRequestJoinOtherRoom: (info: IPKInviteInfo) => {};
|
|
2100
|
+
/**
|
|
2101
|
+
* 收到取消连麦邀请
|
|
2102
|
+
*/
|
|
2103
|
+
onCancelRequestOtherRoom: (info: IPKInviteInfo) => {};
|
|
2104
|
+
/**
|
|
2105
|
+
* 收到连麦 PK 请求响应结果
|
|
2106
|
+
*/
|
|
2107
|
+
onResponseJoinOtherRoom: (info: IPKInviteAnswerInfo) => {};
|
|
2108
|
+
/**
|
|
2109
|
+
* 收到 PK 结束
|
|
2110
|
+
*/
|
|
2111
|
+
onFinishOtherRoom: (info: IPKEndInfo) => {};
|
|
2112
|
+
}
|
|
2113
|
+
declare class RCLivingPKHandler {
|
|
2114
|
+
private readonly _context;
|
|
2115
|
+
private readonly _runtime;
|
|
2116
|
+
private readonly _service;
|
|
2117
|
+
private readonly _initOptions;
|
|
2118
|
+
/**
|
|
2119
|
+
* 主直播房间
|
|
2120
|
+
*/
|
|
2121
|
+
private readonly _mainLivingRoom;
|
|
2122
|
+
private readonly _registerPKMsgListener;
|
|
2123
|
+
/**
|
|
2124
|
+
* 加入 PK 房间回调
|
|
2125
|
+
*/
|
|
2126
|
+
private readonly _onJoinedPKRoom;
|
|
2127
|
+
/**
|
|
2128
|
+
* 退出 PK 房间回调
|
|
2129
|
+
*/
|
|
2130
|
+
private readonly _onLeavePKRoom;
|
|
2131
|
+
/**
|
|
2132
|
+
* PK 邀请超时时间,默认 30s
|
|
2133
|
+
*/
|
|
2134
|
+
private readonly _inviteTimeout;
|
|
2135
|
+
/**
|
|
2136
|
+
* PK 房间信息
|
|
2137
|
+
*/
|
|
2138
|
+
private _PKInfo;
|
|
2139
|
+
private _appListener;
|
|
2140
|
+
private _mainRoomId;
|
|
2141
|
+
/**
|
|
2142
|
+
* 跨房间连麦加入的 PK 房间
|
|
2143
|
+
*/
|
|
2144
|
+
private _joinedPKRooms;
|
|
2145
|
+
constructor(_context: RTCPluginContext, _runtime: IRuntime, _service: RCMediaService, _initOptions: IRCRTCInitOptions,
|
|
2146
|
+
/**
|
|
2147
|
+
* 主直播房间
|
|
2148
|
+
*/
|
|
2149
|
+
_mainLivingRoom: RCLivingRoom, _registerPKMsgListener: (listener: IOnRecvPKMsg) => void,
|
|
2150
|
+
/**
|
|
2151
|
+
* 加入 PK 房间回调
|
|
2152
|
+
*/
|
|
2153
|
+
_onJoinedPKRoom: (roomId: string, room: RCLivingRoom) => void,
|
|
2154
|
+
/**
|
|
2155
|
+
* 退出 PK 房间回调
|
|
2156
|
+
*/
|
|
2157
|
+
_onLeavePKRoom: (roomId: string) => void);
|
|
2158
|
+
private _callAppListener;
|
|
2159
|
+
/**
|
|
2160
|
+
* 收到连麦邀请
|
|
2161
|
+
*/
|
|
2162
|
+
private _onInvite;
|
|
2163
|
+
/**
|
|
2164
|
+
* 收到取消连麦
|
|
2165
|
+
*/
|
|
2166
|
+
private _onCancelInvite;
|
|
2167
|
+
private _onInviteTimeout;
|
|
2168
|
+
/**
|
|
2169
|
+
* 收到响应连麦
|
|
2170
|
+
*/
|
|
2171
|
+
private _onInviteAnswer;
|
|
2172
|
+
/**
|
|
2173
|
+
* 收到连麦结束
|
|
2174
|
+
*/
|
|
2175
|
+
private _onPKEnd;
|
|
2176
|
+
/**
|
|
2177
|
+
* 处理跨房间连麦相关消息
|
|
2178
|
+
*/
|
|
2179
|
+
private _onRecvPKMsg;
|
|
2180
|
+
/**
|
|
2181
|
+
* 注册跨房间连麦监听事件
|
|
2182
|
+
*/
|
|
2183
|
+
registerRoomPKEventListener(listener: IRoomPKEventListener): void;
|
|
2184
|
+
/**
|
|
2185
|
+
* 发起跨房间连麦请求
|
|
2186
|
+
* @param inviteeRoomId 被邀请者所处的房间 roomId
|
|
2187
|
+
* @param inviteeUserId 被邀请者 userId
|
|
2188
|
+
* @param options.autoMix 是否要把邀请者发布的资源,合并到被邀请者房间内的 MCU 流中
|
|
2189
|
+
* @param options.extra 拓展字段,可随邀请连麦消息透传给被邀请者
|
|
2190
|
+
*/
|
|
2191
|
+
requestJoinOtherRoom(inviteeRoomId: string, inviteeUserId: string, options?: IReqResPKOptions): Promise<{
|
|
2192
|
+
code: RCRTCCode | ErrorCode;
|
|
2193
|
+
}>;
|
|
2194
|
+
/**
|
|
2195
|
+
* 取消跨房间连麦请求
|
|
2196
|
+
* @param inviteeRoomId 被邀请者所处的房间 roomId
|
|
2197
|
+
* @param inviteeUserId 被邀请者 userId
|
|
2198
|
+
* @param extra 附加信息,可随取消邀请连麦消息透传给被邀请者
|
|
2199
|
+
*/
|
|
2200
|
+
cancelRequestJoinOtherRoom(inviteeRoomId: string, inviteeUserId: string, extra?: string): Promise<{
|
|
2201
|
+
code: RCRTCCode | ErrorCode;
|
|
2202
|
+
}>;
|
|
2203
|
+
/**
|
|
2204
|
+
* 响应跨房间连麦请求
|
|
2205
|
+
* @param inviterRoomId 邀请者所处的房间 roomId
|
|
2206
|
+
* @param inviterUserId 邀请者 userId
|
|
2207
|
+
* @param agree 是否同意连麦
|
|
2208
|
+
* @param options.autoMix 是否要把被邀请者发布的资源,合并到邀请者房间内的 MCU 流中
|
|
2209
|
+
* @param options.extra 附加信息,可随响应连麦消息透传给邀请者
|
|
2210
|
+
*/
|
|
2211
|
+
responseJoinOtherRoom(inviterRoomId: string, inviterUserId: string, agree: boolean, options?: IReqResPKOptions): Promise<{
|
|
2212
|
+
code: RCRTCCode | ErrorCode;
|
|
2213
|
+
}>;
|
|
2214
|
+
/**
|
|
2215
|
+
* 结束跨房间连麦
|
|
2216
|
+
* @param roomId 需要结束连麦的房间 roomId
|
|
2217
|
+
*/
|
|
2218
|
+
private _quitRoomPK;
|
|
2219
|
+
private _relaseCrtRoom;
|
|
2220
|
+
/**
|
|
2221
|
+
* 加入副直播房间
|
|
2222
|
+
* @roomId 副房间的 roomId
|
|
2223
|
+
*/
|
|
2224
|
+
joinOtherRoom(roomId: string): Promise<{
|
|
2225
|
+
code: RCRTCCode;
|
|
2226
|
+
room?: RCLivingRoom;
|
|
2227
|
+
userIds?: string[];
|
|
2228
|
+
tracks?: RCRemoteTrack[];
|
|
2229
|
+
CDNEnable?: boolean;
|
|
2230
|
+
}>;
|
|
2231
|
+
/**
|
|
2232
|
+
* 退出副房间
|
|
2233
|
+
* @param room 要退出的副房间的 room 实例
|
|
2234
|
+
* @param isQuitPK 是否要结束连麦
|
|
2235
|
+
*/
|
|
2236
|
+
leaveOtherRoom(room: RCLivingRoom, isQuitPK?: boolean): Promise<{
|
|
2237
|
+
code: RCRTCCode;
|
|
2238
|
+
}>;
|
|
2239
|
+
/**
|
|
2240
|
+
* 获取连麦信息
|
|
2241
|
+
* @param roomId 连麦房间的 roomId
|
|
2242
|
+
*/
|
|
2243
|
+
getPKInfo(roomId: string): {
|
|
2244
|
+
inviteSessionId: string;
|
|
2245
|
+
inviterRoomId: string;
|
|
2246
|
+
inviterUserId: string;
|
|
2247
|
+
inviterUserAutoMix?: boolean | undefined;
|
|
2248
|
+
inviteeRoomId: string;
|
|
2249
|
+
inviteeUserAutoMix?: boolean | undefined;
|
|
2250
|
+
};
|
|
2251
|
+
/**
|
|
2252
|
+
* 获取已加入的副房间
|
|
2253
|
+
*/
|
|
2254
|
+
getJoinedPKRooms(): {
|
|
2255
|
+
[roomId: string]: RCLivingRoom;
|
|
2256
|
+
};
|
|
2257
|
+
}
|
|
2258
|
+
|
|
2030
2259
|
/**
|
|
2031
2260
|
* 房间抽象基类
|
|
2032
2261
|
*/
|
|
@@ -2038,6 +2267,7 @@ declare abstract class RCAbstractRoom {
|
|
|
2038
2267
|
protected readonly _service: RCMediaService;
|
|
2039
2268
|
protected readonly _initOptions: IRCRTCInitOptions;
|
|
2040
2269
|
private readonly _ntfClearRoomItem;
|
|
2270
|
+
protected _isMainRoom?: boolean | undefined;
|
|
2041
2271
|
/**
|
|
2042
2272
|
* 房间资源数据
|
|
2043
2273
|
*/
|
|
@@ -2049,7 +2279,7 @@ declare abstract class RCAbstractRoom {
|
|
|
2049
2279
|
/**
|
|
2050
2280
|
* 已订阅参数
|
|
2051
2281
|
*/
|
|
2052
|
-
|
|
2282
|
+
protected readonly _subscribedList: ISubscribeAttr[];
|
|
2053
2283
|
/**
|
|
2054
2284
|
* 房间保活 rtcPing
|
|
2055
2285
|
*/
|
|
@@ -2065,7 +2295,7 @@ declare abstract class RCAbstractRoom {
|
|
|
2065
2295
|
/**
|
|
2066
2296
|
* PeerConnection 连接实例
|
|
2067
2297
|
*/
|
|
2068
|
-
|
|
2298
|
+
protected readonly _pc: RCRTCPeerConnection;
|
|
2069
2299
|
private _destroyed;
|
|
2070
2300
|
/**
|
|
2071
2301
|
* 北极星上报实例
|
|
@@ -2075,7 +2305,7 @@ declare abstract class RCAbstractRoom {
|
|
|
2075
2305
|
* 音量上报实例
|
|
2076
2306
|
*/
|
|
2077
2307
|
private _audioLevelReport;
|
|
2078
|
-
constructor(_context: RTCPluginContext, _runtime: IRuntime, _roomId: string, data: IJoinRTCRoomData, _roomMode: RTCMode, _service: RCMediaService, _initOptions: IRCRTCInitOptions, _ntfClearRoomItem: Function, isUpgrade?: boolean);
|
|
2308
|
+
constructor(_context: RTCPluginContext, _runtime: IRuntime, _roomId: string, data: IJoinRTCRoomData, _roomMode: RTCMode, _service: RCMediaService, _initOptions: IRCRTCInitOptions, _ntfClearRoomItem: Function, isUpgrade?: boolean, _isMainRoom?: boolean | undefined);
|
|
2079
2309
|
private _initRemoteTracks;
|
|
2080
2310
|
private _handlePingResult;
|
|
2081
2311
|
/**
|
|
@@ -2251,6 +2481,14 @@ declare abstract class RCAbstractRoom {
|
|
|
2251
2481
|
liveUrl?: string;
|
|
2252
2482
|
}>;
|
|
2253
2483
|
private __publish;
|
|
2484
|
+
/**
|
|
2485
|
+
* 获取跨房间连麦需携带参数 pushOtherRooms 的值
|
|
2486
|
+
*/
|
|
2487
|
+
protected _getPushOtherRoomsParams(): {
|
|
2488
|
+
roomId: string;
|
|
2489
|
+
sessionId: string;
|
|
2490
|
+
autoMix: boolean;
|
|
2491
|
+
}[] | undefined;
|
|
2254
2492
|
/**
|
|
2255
2493
|
* ice 断线后,尝试重新走 exchange
|
|
2256
2494
|
*/
|
|
@@ -2367,6 +2605,18 @@ declare abstract class RCAbstractRoom {
|
|
|
2367
2605
|
* 销毁远端资源
|
|
2368
2606
|
*/
|
|
2369
2607
|
private _removeRemoteTracks;
|
|
2608
|
+
/**
|
|
2609
|
+
* 存储连麦监听事件
|
|
2610
|
+
*/
|
|
2611
|
+
private _onRecvPKMsg;
|
|
2612
|
+
/**
|
|
2613
|
+
* 注册 PK 业务监听方法
|
|
2614
|
+
*/
|
|
2615
|
+
protected _registerPKMsgListener(listener: IOnRecvPKMsg | null): void;
|
|
2616
|
+
/**
|
|
2617
|
+
* 退出 PK 房间
|
|
2618
|
+
*/
|
|
2619
|
+
protected _quitAllPKRoom(): void;
|
|
2370
2620
|
}
|
|
2371
2621
|
|
|
2372
2622
|
/**
|
|
@@ -2544,18 +2794,37 @@ declare class RCMCUConfigBuilder {
|
|
|
2544
2794
|
*/
|
|
2545
2795
|
declare class RCLivingRoom extends RCAbstractRoom {
|
|
2546
2796
|
private _livingType;
|
|
2797
|
+
/**
|
|
2798
|
+
* 是否是主房间
|
|
2799
|
+
*/
|
|
2800
|
+
protected _isMainRoom: boolean;
|
|
2547
2801
|
readonly _mcuConfigBuilder: RCMCUConfigBuilder;
|
|
2548
2802
|
/**
|
|
2549
2803
|
* cdn_uris 信令扩散数据
|
|
2550
2804
|
*/
|
|
2551
2805
|
private _CDNUris;
|
|
2552
2806
|
private _CDNEnable;
|
|
2553
|
-
|
|
2807
|
+
/**
|
|
2808
|
+
* 跨房间连麦管理器
|
|
2809
|
+
*/
|
|
2810
|
+
private readonly _roomPKHandler;
|
|
2811
|
+
constructor(context: RTCPluginContext, runtime: IRuntime, roomId: string, data: IJoinRTCRoomData, service: RCMediaService, initOptions: IRCRTCInitOptions, clientEvent: Function, _livingType: RCLivingType, isUpgrage: boolean | undefined,
|
|
2812
|
+
/**
|
|
2813
|
+
* 是否是主房间
|
|
2814
|
+
*/
|
|
2815
|
+
_isMainRoom: boolean);
|
|
2816
|
+
/**
|
|
2817
|
+
* resourceId 有效性验证
|
|
2818
|
+
* @param resourceId
|
|
2819
|
+
*/
|
|
2820
|
+
protected _isValidResourceId(resourceId: string): boolean;
|
|
2554
2821
|
getLivingType(): RCLivingType;
|
|
2555
2822
|
/**
|
|
2556
2823
|
* 获取 MCU 配置构建对象
|
|
2557
2824
|
*/
|
|
2558
|
-
getMCUConfigBuilder(): RCMCUConfigBuilder
|
|
2825
|
+
getMCUConfigBuilder(): RCMCUConfigBuilder | {
|
|
2826
|
+
code: RCRTCCode;
|
|
2827
|
+
};
|
|
2559
2828
|
/**
|
|
2560
2829
|
* 接收 MCU 配置并向 MediaServer 提交
|
|
2561
2830
|
* @param data
|
|
@@ -2622,6 +2891,30 @@ declare class RCLivingRoom extends RCAbstractRoom {
|
|
|
2622
2891
|
* @returns boolean
|
|
2623
2892
|
*/
|
|
2624
2893
|
__getCDNPushMode(): RCInnerCDNPushMode | undefined;
|
|
2894
|
+
/**
|
|
2895
|
+
* 加入 PK 房间回调
|
|
2896
|
+
*/
|
|
2897
|
+
private _onJoinedPKRoom;
|
|
2898
|
+
/**
|
|
2899
|
+
* 离开 PK 房间后,如果参与过连麦,pushOtherRooms 需去掉退出的连麦房间配置,重新和 mediaServer 交互
|
|
2900
|
+
*/
|
|
2901
|
+
private _onLeavePKRoom;
|
|
2902
|
+
/**
|
|
2903
|
+
* 携带 pushOtherRooms 与 mediaServer 重新交互
|
|
2904
|
+
*/
|
|
2905
|
+
private _exchangeWithPushOtherRoom;
|
|
2906
|
+
/**
|
|
2907
|
+
* 获取 PK 业务处理器
|
|
2908
|
+
* @since version 5.3.0
|
|
2909
|
+
*/
|
|
2910
|
+
getRoomPKHandler(): {
|
|
2911
|
+
code: RCRTCCode;
|
|
2912
|
+
roomPKHandler?: RCLivingPKHandler;
|
|
2913
|
+
};
|
|
2914
|
+
/**
|
|
2915
|
+
* 退出所有连麦房间
|
|
2916
|
+
*/
|
|
2917
|
+
protected _quitAllPKRoom(): void;
|
|
2625
2918
|
}
|
|
2626
2919
|
|
|
2627
2920
|
/**
|
|
@@ -2708,6 +3001,10 @@ declare class RCRTCClient {
|
|
|
2708
3001
|
private readonly _service;
|
|
2709
3002
|
constructor(_context: RTCPluginContext, _runtime: IRuntime, _options: IRCRTCInitOptions);
|
|
2710
3003
|
private _handleMessage;
|
|
3004
|
+
/**
|
|
3005
|
+
* 获取加入的连麦房间
|
|
3006
|
+
*/
|
|
3007
|
+
private _getJoinedPKRoomList;
|
|
2711
3008
|
/**
|
|
2712
3009
|
* 获取当前用户 Id,若 IM 未连接,这返回 `''`
|
|
2713
3010
|
* @returns
|
|
@@ -2796,7 +3093,7 @@ declare class RCRTCClient {
|
|
|
2796
3093
|
* @param tag 屏幕共享视轨数据标识
|
|
2797
3094
|
* @param options
|
|
2798
3095
|
* @description
|
|
2799
|
-
* 支持 Electron 平台下通过制定 `
|
|
3096
|
+
* 支持 Electron 平台下通过制定 `chromeMediaSourceId` 的方式获取屏幕共享视频。
|
|
2800
3097
|
* 参考:https://www.electronjs.org/docs/api/desktop-capturer
|
|
2801
3098
|
*/
|
|
2802
3099
|
createScreenVideoTrack(tag?: string, options?: IScreenVideoProfile): Promise<{
|
|
@@ -2871,6 +3168,8 @@ declare class RCRTCClient {
|
|
|
2871
3168
|
upgradeToAnchorRoom(room: RCAudienceLivingRoom): Promise<{
|
|
2872
3169
|
room?: RCLivingRoom;
|
|
2873
3170
|
code: RCRTCCode;
|
|
3171
|
+
userIds?: string[];
|
|
3172
|
+
tracks?: RCRemoteTrack[];
|
|
2874
3173
|
}>;
|
|
2875
3174
|
/**
|
|
2876
3175
|
* 降级为观众房间
|
|
@@ -2941,4 +3240,4 @@ declare const helper: {
|
|
|
2941
3240
|
ifSupportScreenShare: typeof ifSupportScreenShare;
|
|
2942
3241
|
};
|
|
2943
3242
|
|
|
2944
|
-
export { BackgroundPictureFillMode, ICameraVideoProfile, IMCUOutputConfig, IMCUOutputVideoConfig, IMicphoneAudioProfile, IPublishAttrs, IPublishedResource, IRCCandidatePairStat, IRCRTCInitOptions, IRCRTCReportListener, IRCRTCStateReport, IRCTrackStat, IRoomEventListener, ISubscribeAttr, IVideoProfile, MixLayoutMode, MixVideoRenderMode, RCAbstractRoom, RCAudienceClient, RCAudienceLivingRoom, RCCameraVideoTrack, RCFrameRate, RCInnerCDNPullIsHttps, RCInnerCDNPullKind, RCKickReason, RCLivingRoom, RCLivingType, RCLocalAudioTrack, RCLocalFileAudioTrack, RCLocalFileTrack, RCLocalFileVideoTrack, RCLocalTrack, RCLocalVideoTrack, RCMCUConfigBuilder, RCMediaType, RCMicphoneAudioTrack, RCRTCClient, RCRTCCode, RCRTCLiveRole, RCRTCPingResult, RCRTCRoom, RCRemoteAudioTrack, RCRemoteTrack, RCRemoteVideoTrack, RCResolution, RCScreenVideoTrack, RCTag, RCTrack, device, helper, installer };
|
|
3243
|
+
export { BackgroundPictureFillMode, ICameraVideoProfile, IMCUOutputConfig, IMCUOutputVideoConfig, IMicphoneAudioProfile, IPKEndInfo, IPKInviteAnswerInfo, IPKInviteInfo, IPublishAttrs, IPublishedResource, IRCCandidatePairStat, IRCRTCInitOptions, IRCRTCReportListener, IRCRTCStateReport, IRCTrackStat, IReqResPKOptions, IRoomEventListener, IRoomPKEventListener, ISubscribeAttr, IVideoProfile, MixLayoutMode, MixVideoRenderMode, RCAbstractRoom, RCAudienceClient, RCAudienceLivingRoom, RCCameraVideoTrack, RCFrameRate, RCInnerCDNPullIsHttps, RCInnerCDNPullKind, RCKickReason, RCLivingRoom, RCLivingType, RCLocalAudioTrack, RCLocalFileAudioTrack, RCLocalFileTrack, RCLocalFileVideoTrack, RCLocalTrack, RCLocalVideoTrack, RCMCUConfigBuilder, RCMediaType, RCMicphoneAudioTrack, RCRTCClient, RCRTCCode, RCRTCLiveRole, RCRTCPingResult, RCRTCRoom, RCRemoteAudioTrack, RCRemoteTrack, RCRemoteVideoTrack, RCResolution, RCScreenVideoTrack, RCTag, RCTrack, device, helper, installer };
|