fcr-core
Version:
Core APIs for building online scenes
172 lines (136 loc) • 7.67 kB
JavaScript
// 基础导入类型(集中管理第三方依赖类型别名)
// 内部枚举与基础类型导入
import { FcrUserRole } from './room-control/user-control/type';
// 模块类型导出(按功能模块分组)
// 聊天连接模块
// 第三方类型别名(统一前缀避免冲突)
export { AgoraRtcAiDenoiseLevel as FcrAiDenoiseLevel, AgoraRtcAudioSourceType as FcrAudioSourceType, AgoraRtcCapability as FcrCapability, AgoraRteConnectionState as FcrConnectionState, AgoraRtcMediaSourceState as FcrMediaSourceState, AgoraRteRegion as FcrRegion, AgoraRteRoomConnectorType as FcrRoomConnectorType, AgoraRteScreenCaptureType as FcrScreenCaptureType, AgoraRteLatencyLevel as FcrStreamLatencyLevel, AgoraRteStreamPrivilegeAudioSourceType as FcrStreamPrivilegeAudioSourceType, AgoraRteStreamPrivilegeOperation as FcrStreamPrivilegeOperation, AgoraRteStreamPrivilegeVideoSourceType as FcrStreamPrivilegeVideoSourceType, AgoraRteMediaStreamType as FcrStreamType, AgoraRteUserUpdatedReason as FcrUserUpdatedReason, AgoraRteVideoOrientation as FcrVideoOrientation, AgoraRtcRenderMode as FcrVideoRenderMode, AgoraRtcVideoSourceType as FcrVideoSourceType, AgoraRtcVideoStreamType as FcrVideoStreamType, registerPlugin } from './imports';
import { FcrDualVideoStreamConfig } from './utilities/dual-video-stream-config';
import { FcrVideoEncoderConfig } from './utilities/video-encoder-config';
// 基础类型别名(简化常用类型引用)
export { FcrDualVideoStreamConfig };
// 媒体控制模块
// 监控控制模块
// 点对点会话模块
// 房间控制模块 - 能力控制
export { FcrAbility } from './room-control/ability-control/type';
// 房间控制模块 - 聊天室控制
export { FcrChatRoomConnectionState, FcrChatRoomMessageType } from './room-control/chatroom-control/type';
// 房间控制模块 - 翻译控制
export { FcrInterpreterActionType, FcrLanguage } from './room-control/interpreter-control/types';
// 房间控制模块 - 权限控制
export { FcrChatPermissionType, FcrOperatePermissionType, FcrPermissionAction, FcrPrivilegeUserRole, FcrPrivilegeUserRoleToStringMap, FcrPrivilegeUserStringToRoleMap, FcrSecurityAction, FcrWatermarkPermissionState } from './room-control/privilege-control/type';
// 房间控制模块 - 连接器控制
export { FcrIPConnectorSessionType, FcrRoomConnectorPhoneRegion, FcrRoomConnectorSessionReason, FcrRoomConnectorSessionState } from './room-control/room-connector-control/type';
export { FcrRemoteControlState } from './remote-control/type';
// 房间控制模块 - 房间会话
// 房间控制模块 - 共享控制
export { FcrScreenSharingState, FcrWhiteboardState } from './room-control/sharing-control/type';
// 房间控制模块 - 流控制
// 房间控制模块 - 用户控制
export { FcrUserKickedOutType, FcrUserLeftReason, FcrUserRole } from './room-control/user-control/type';
// 房间控制模块 - 白板标注控制
// 房间控制模块 - 白板控制
// 房间路由模块
// 服务相关类型
export { FcrVideoEncoderConfig };
// 核心引擎类型扩展
// 房间相关核心类型
export let FcrRoomState = /*#__PURE__*/function (FcrRoomState) {
FcrRoomState[FcrRoomState["Initialized"] = 0] = "Initialized";
FcrRoomState[FcrRoomState["Started"] = 1] = "Started";
FcrRoomState[FcrRoomState["Ended"] = 2] = "Ended";
FcrRoomState[FcrRoomState["Closed"] = 3] = "Closed";
return FcrRoomState;
}({});
export let FcrRecordingState = /*#__PURE__*/function (FcrRecordingState) {
FcrRecordingState[FcrRecordingState["Starting"] = 1] = "Starting";
FcrRecordingState[FcrRecordingState["Started"] = 2] = "Started";
FcrRecordingState[FcrRecordingState["Paused"] = 3] = "Paused";
FcrRecordingState[FcrRecordingState["Stopped"] = 4] = "Stopped";
return FcrRecordingState;
}({});
/** 房间基本信息 */
/** 平台类型枚举 */
export let FcrPlatform = /*#__PURE__*/function (FcrPlatform) {
FcrPlatform[FcrPlatform["UNSUPPORTED"] = -1] = "UNSUPPORTED";
FcrPlatform[FcrPlatform["WEB_DESKTOP"] = 1] = "WEB_DESKTOP";
FcrPlatform[FcrPlatform["MACOS"] = 2] = "MACOS";
FcrPlatform[FcrPlatform["WINDOWS"] = 3] = "WINDOWS";
FcrPlatform[FcrPlatform["IOS"] = 4] = "IOS";
FcrPlatform[FcrPlatform["ANDROID"] = 5] = "ANDROID";
FcrPlatform[FcrPlatform["WEB_MOBILE"] = 6] = "WEB_MOBILE";
FcrPlatform[FcrPlatform["HARMONY"] = 7] = "HARMONY";
FcrPlatform[FcrPlatform["LINUX"] = 8] = "LINUX";
FcrPlatform[FcrPlatform["CONNECTOR_PSTN"] = 101] = "CONNECTOR_PSTN";
FcrPlatform[FcrPlatform["CONNECTOR_SIP"] = 102] = "CONNECTOR_SIP";
FcrPlatform[FcrPlatform["CONNECTOR_H323"] = 103] = "CONNECTOR_H323";
return FcrPlatform;
}({});
/** 用户信息类型 */
/** 流信息类型 */
/** 房间日程安排 */
/** 录制信息 */
// 群组相关类型
// 群组事件类型(统一事件格式)
// 房间路由事件
// 会话相关类型
// 媒体设备相关类型
// 性能与网络相关类型
// 云端录制配置
export let FcrCloudRecordingAudioProfile = /*#__PURE__*/function (FcrCloudRecordingAudioProfile) {
FcrCloudRecordingAudioProfile[FcrCloudRecordingAudioProfile["DEFAULT"] = 0] = "DEFAULT";
// mono 单声道 48khz 48kbps
FcrCloudRecordingAudioProfile[FcrCloudRecordingAudioProfile["MONO_48KHZ_128KBPS"] = 1] = "MONO_48KHZ_128KBPS";
// mono 单声道 48khz 128kbps
FcrCloudRecordingAudioProfile[FcrCloudRecordingAudioProfile["STEREO_48KHZ_192KBPS"] = 2] = "STEREO_48KHZ_192KBPS"; // stereo 立体声 48khz 192kbps
return FcrCloudRecordingAudioProfile;
}({});
export const FcrUserRoleToStringMap = {
[FcrUserRole.HOST]: 'host',
[FcrUserRole.COHOST]: 'cohost',
[FcrUserRole.PARTICIPANT]: 'participant',
[FcrUserRole.AUDIENCE]: 'audience',
[FcrUserRole.OBSERVER]: 'observer',
[FcrUserRole.ROBOT]: 'robot'
};
export const FcrUserStringToRoleMap = {
host: FcrUserRole.HOST,
cohost: FcrUserRole.COHOST,
participant: FcrUserRole.PARTICIPANT,
audience: FcrUserRole.AUDIENCE,
observer: FcrUserRole.OBSERVER,
robot: FcrUserRole.ROBOT
};
export let FcrReturnCode = /*#__PURE__*/function (FcrReturnCode) {
FcrReturnCode[FcrReturnCode["UNDEFINED"] = -1] = "UNDEFINED";
FcrReturnCode[FcrReturnCode["SUCCESS"] = 0] = "SUCCESS";
return FcrReturnCode;
}({});
// 直播相关类型
export let FcrLiveStreamingLayoutType = /*#__PURE__*/function (FcrLiveStreamingLayoutType) {
FcrLiveStreamingLayoutType[FcrLiveStreamingLayoutType["GALLERY"] = 1] = "GALLERY";
// 画廊模式
FcrLiveStreamingLayoutType[FcrLiveStreamingLayoutType["SPEAKER"] = 2] = "SPEAKER"; // 主讲模式
return FcrLiveStreamingLayoutType;
}({});
export let FcrLiveStreamingState = /*#__PURE__*/function (FcrLiveStreamingState) {
FcrLiveStreamingState[FcrLiveStreamingState["STARTING"] = 1] = "STARTING";
FcrLiveStreamingState[FcrLiveStreamingState["STARTED"] = 2] = "STARTED";
FcrLiveStreamingState[FcrLiveStreamingState["STOPPED"] = 3] = "STOPPED";
return FcrLiveStreamingState;
}({});
export let RoomMessageKey = /*#__PURE__*/function (RoomMessageKey) {
RoomMessageKey["USER_WAITING_ROOM_JOINED"] = "USER_WAITING_ROOM_JOINED";
RoomMessageKey["USER_BANNED_CHAT_HISTORY"] = "USER_BANNED_CHAT_HISTORY";
return RoomMessageKey;
}({});
export { FcrDeviceType } from './media-control/type';
export { FcrLineType } from './room-control/type';
export { FcrError } from './utilities/error';
export let FcrStreamState = /*#__PURE__*/function (FcrStreamState) {
FcrStreamState[FcrStreamState["UNPUBLISH"] = 0] = "UNPUBLISH";
FcrStreamState[FcrStreamState["PUBLISH"] = 1] = "PUBLISH";
return FcrStreamState;
}({});
export { FcrBoardShape, FcrBoardToolType } from './room-control/whiteboard-control-v2/enum';