@rongcloud/plugin-rtc 5.6.11 → 5.6.13-alpha.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 +19 -11
- package/dist/index.esm.js +17023 -9236
- package/dist/index.umd.js +21659 -143
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -236,7 +236,7 @@ declare abstract class RCTrack extends EventEmitter {
|
|
|
236
236
|
* 发布者是否已禁用该轨道数据,在 RCLocalTrack 实例中,则其值始终等于 `isLocalMuted()`
|
|
237
237
|
*/
|
|
238
238
|
isOwnerMuted(): boolean;
|
|
239
|
-
|
|
239
|
+
protected _element?: HTMLMediaElement;
|
|
240
240
|
/**
|
|
241
241
|
* 播放
|
|
242
242
|
* @param element 用于承载媒体流的元素标签,音频流可传空
|
|
@@ -441,7 +441,7 @@ declare class RCScreenVideoTrack extends RCLocalVideoTrack {
|
|
|
441
441
|
declare class RCScreenAudioTrack extends RCLocalAudioTrack {
|
|
442
442
|
}
|
|
443
443
|
|
|
444
|
-
declare class RCRemoteTrack extends RCTrack {
|
|
444
|
+
declare abstract class RCRemoteTrack extends RCTrack {
|
|
445
445
|
constructor(logger: BasicLogger, tag: string, userId: string, kind: 'audio' | 'video', roomId?: string);
|
|
446
446
|
/**
|
|
447
447
|
* 根据房间数据更新状态
|
|
@@ -458,6 +458,12 @@ declare class RCRemoteTrack extends RCTrack {
|
|
|
458
458
|
}
|
|
459
459
|
declare class RCRemoteAudioTrack extends RCRemoteTrack {
|
|
460
460
|
constructor(logger: BasicLogger, tag: string, userId: string, roomId?: string);
|
|
461
|
+
/**
|
|
462
|
+
* 获取播放时指定的输出音量。若当前未播放,则返回 0。
|
|
463
|
+
* 注意:该音量为对媒体输出设备设定的输出音量,与当前音频内容的 audioLevel 是不同概念。
|
|
464
|
+
* @since - v5.6.12
|
|
465
|
+
*/
|
|
466
|
+
getVolume(): number;
|
|
461
467
|
}
|
|
462
468
|
declare class RCRemoteVideoTrack extends RCRemoteTrack {
|
|
463
469
|
constructor(logger: BasicLogger, tag: string, userId: string, roomId?: string);
|
|
@@ -1063,10 +1069,11 @@ declare abstract class ReadableStore {
|
|
|
1063
1069
|
*/
|
|
1064
1070
|
protected _trackIdSSRCMap: Map<number, string>;
|
|
1065
1071
|
protected _roomStatusVersion: number;
|
|
1072
|
+
protected _supportNtf: boolean;
|
|
1066
1073
|
constructor(_logger: BasicLogger, clientSessionId: string, appkey: string, roomId: string, crtUserId: string, roomMode: RTCMode, isUpgrade?: boolean | undefined, isMainRoom?: boolean | undefined);
|
|
1067
1074
|
getResourcesByUserId(userId: string): IPublishedResource[] | undefined;
|
|
1068
|
-
getRemoteTrack(trackId: string):
|
|
1069
|
-
getRemoteTracksByUserId(userId: string):
|
|
1075
|
+
getRemoteTrack(trackId: string): RCRemoteAudioTrack | RCRemoteVideoTrack | undefined;
|
|
1076
|
+
getRemoteTracksByUserId(userId: string): (RCRemoteAudioTrack | RCRemoteVideoTrack)[];
|
|
1070
1077
|
getRemoteTracks(): {
|
|
1071
1078
|
[trackId: string]: RCRemoteAudioTrack | RCRemoteVideoTrack;
|
|
1072
1079
|
};
|
|
@@ -1082,6 +1089,7 @@ declare abstract class ReadableStore {
|
|
|
1082
1089
|
getRoomStatusVersion(): number;
|
|
1083
1090
|
getTrackIdBySSRC(ssrc: number): string | undefined;
|
|
1084
1091
|
getRTCRequestHeader(): IRTCReqHeader;
|
|
1092
|
+
getSupportNtf(): boolean;
|
|
1085
1093
|
}
|
|
1086
1094
|
declare class Store extends ReadableStore {
|
|
1087
1095
|
/**
|
|
@@ -1095,7 +1103,7 @@ declare class Store extends ReadableStore {
|
|
|
1095
1103
|
setResourcesByUserId(userId: string, arr: IPublishedResource[]): void;
|
|
1096
1104
|
removeRemoteTrack(trackId: string): void;
|
|
1097
1105
|
removeResourcesByUserId(userId: string): void;
|
|
1098
|
-
addRemoteTrack(track:
|
|
1106
|
+
addRemoteTrack(track: RCRemoteAudioTrack | RCRemoteVideoTrack): void;
|
|
1099
1107
|
removeRemoteTracks(): void;
|
|
1100
1108
|
setCDNEnabel(bool: boolean): void;
|
|
1101
1109
|
setCDNUris(uris: ICDNUris | null): void;
|
|
@@ -2458,7 +2466,7 @@ declare class RTCContext {
|
|
|
2458
2466
|
roomCreateTime: number | undefined;
|
|
2459
2467
|
userJoinTime: number | undefined;
|
|
2460
2468
|
constructor(context: RTCPluginContext, logger: BasicLogger, codec: Codec<RTCKeyMaps>);
|
|
2461
|
-
joinRTCRoom(roomId: string, mode: RTCMode, broadcastType?: number, joinType?: RTCJoinType, innerUserDatas?: IRTCUserData, outerUserDatas?: IRTCUserData): IPromiseResult<IJoinRTCRoomData>;
|
|
2469
|
+
joinRTCRoom(roomId: string, mode: RTCMode, broadcastType?: number, joinType?: RTCJoinType, innerUserDatas?: IRTCUserData, outerUserDatas?: IRTCUserData, supportNtf?: boolean): IPromiseResult<IJoinRTCRoomData>;
|
|
2462
2470
|
quitRTCRoom(roomId: string): Promise<ErrorCode>;
|
|
2463
2471
|
getRTCRoomInfo(roomId: string): IPromiseResult<IRTCRoomInfo>;
|
|
2464
2472
|
getRTCUserInfoList(roomId: string): IPromiseResult<IRTCUsers>;
|
|
@@ -3697,7 +3705,7 @@ declare class RCLivingPKHandler {
|
|
|
3697
3705
|
* 发起跨房间连麦请求
|
|
3698
3706
|
* @param inviteeRoomId 被邀请者所处的房间 roomId
|
|
3699
3707
|
* @param inviteeUserId 被邀请者 userId
|
|
3700
|
-
* @param options.autoMix
|
|
3708
|
+
* @param options.autoMix 是否将本房间资源合并到被邀请者所处房间的 MCU 合流中
|
|
3701
3709
|
* @param options.extra 拓展字段,可随邀请连麦消息透传给被邀请者
|
|
3702
3710
|
*/
|
|
3703
3711
|
requestJoinOtherRoom(inviteeRoomId: string, inviteeUserId: string, options?: IReqResPKOptions): Promise<{
|
|
@@ -3717,7 +3725,7 @@ declare class RCLivingPKHandler {
|
|
|
3717
3725
|
* @param inviterRoomId 邀请者所处的房间 roomId
|
|
3718
3726
|
* @param inviterUserId 邀请者 userId
|
|
3719
3727
|
* @param agree 是否同意连麦
|
|
3720
|
-
* @param options.autoMix
|
|
3728
|
+
* @param options.autoMix 是否将本房间资源合并到邀请者所处房间的 MCU 合流中
|
|
3721
3729
|
* @param options.extra 附加信息,可随响应连麦消息透传给邀请者
|
|
3722
3730
|
*/
|
|
3723
3731
|
responseJoinOtherRoom(inviterRoomId: string, inviterUserId: string, agree: boolean, options?: IReqResPKOptions): Promise<{
|
|
@@ -4053,7 +4061,7 @@ declare abstract class RCAbstractRoom extends EventEmitter {
|
|
|
4053
4061
|
* @param trackId
|
|
4054
4062
|
* @returns
|
|
4055
4063
|
*/
|
|
4056
|
-
getRemoteTrack(trackId: string):
|
|
4064
|
+
getRemoteTrack(trackId: string): RCRemoteAudioTrack | RCRemoteVideoTrack | null;
|
|
4057
4065
|
/**
|
|
4058
4066
|
* 获取当前已经订阅的全量资源
|
|
4059
4067
|
* returns subscribedTracks ISubscribeAttr[]
|
|
@@ -4073,8 +4081,8 @@ declare abstract class RCAbstractRoom extends EventEmitter {
|
|
|
4073
4081
|
registerReportListener(listener: IRCRTCReportListener | null): void;
|
|
4074
4082
|
/**
|
|
4075
4083
|
* 音量上报
|
|
4076
|
-
* @param handler
|
|
4077
|
-
* @param _ -
|
|
4084
|
+
* @param handler 音量事件监听函数
|
|
4085
|
+
* @param _ - 参数已废弃,SDK 默认以每秒一次进行回调~~上报时间间隔~~
|
|
4078
4086
|
*/
|
|
4079
4087
|
onAudioLevelChange(handler: IAudioLevelChangeHandler | null, _?: number): void;
|
|
4080
4088
|
/**
|