NERtcEngine class

NERtc 核心接口

Constructors

NERtcEngine()
factory

Properties

audioEffectManager NERtcAudioEffectManager
获取音效管理模块
read-only
audioMixingManager NERtcAudioMixingManager
获取伴音管理模块
read-only
deviceManager NERtcDeviceManager
获取设备管理模块
read-only
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

addLiveStreamTask(NERtcLiveStreamTaskInfo taskInfo, AddLiveTaskCallback callback) Future<int>
添加房间推流任务,成功添加后当前用户可以收到该直播流的状态通知。通话中有效。 taskInfo 直播任务信息 AddLiveTaskCallback 操作结果回调,方法调用成功才有回调
adjustPlaybackSignalVolume(int volume) Future<int>
调节播放音量 加入频道前后都可以调用 调节范围为:0~400 0: 静音 100: 原始音量 (默认) 400: 最大可为原始音量的 4 倍(自带溢出保护) [...]
adjustRecordingSignalVolume(int volume) Future<int>
调节录音音量 加入频道前后都可以调用 调节范围为:0~400 0: 静音 100: 原始音量 (默认) 400: 最大可为原始音量的 4 倍(自带溢出保护) [...]
clearStatsEventCallback() Future<int>
取消统计监听
create({String appKey, NERtcChannelEventCallback channelEventCallback, NERtcOptions options}) Future<void>
创建 NERtc 实例
enableAudioVolumeIndication(bool enable, int interval) Future<int>
启用说话者音量提示。该方法允许 SDK 定期向 App 反馈当前谁在说话以及说话者的音量 [...]
enableDualStreamMode(bool enable) Future<int>
是否开启双流模式 [...]
enableLocalAudio(bool enable) Future<int>
开启/关闭本地语音(采集和发送) [...]
enableLocalVideo(bool enable) Future<int>
开启/关闭本地视频采集以及发送 [...]
getConnectionState() Future<int>
获取连接状态 [...]
joinChannel(String token, String channelName, int uid) Future<int>
加入频道 [...]
leaveChannel() Future<int>
离开频道.
muteLocalAudioStream(bool mute) Future<int>
开关本地音频发送。该方法用于允许/禁止往网络发送本地音频流。
muteLocalVideoStream(bool mute) Future<int>
开关本地视频发送
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
release() Future<int>
销毁 NERtc实例,释放资源
removeLiveStreamTask(String taskId, DeleteLiveTaskCallback callback) Future<int>
删除房间推流任务。通话中有效 [...]
setAudioProfile(NERtcAudioProfile profile, NERtcAudioScenario scenario) Future<int>
设置音频场景与模式,必须在 init 前设置有效。 [...]
setChannelProfile(int channelProfile) Future<int>
设置频道场景 只能在加入频道之前调用 SDK 会根据不同的使用场景采用不同的优化策略,通信场景偏好流畅,直播场景偏好画质。 [...]
setClientRole(int role) Future<int>
设置用户角色 在加入频道前或在频道中,用户可以通过setClientRole 接口设置本端模式为观众或主播模式。 role 用户角色. NERtcClientRole
setLocalVideoConfig(NERtcVideoConfig videoConfig) Future<int>
设置视频参数(分辨率、摄像头位置等)
setStatsEventCallback(NERtcStatsEventCallback callback) Future<int>
设置统计监听
startAudioDump() Future<int>
开始音频dump
startScreenCapture(NERtcScreenConfig config) Future<int>
开启辅流形式的屏幕共享
startVideoPreview() Future<int>
开启视频预览
stopAudioDump() Future<int>
结束音频dump
stopScreenCapture() Future<int>
关闭辅流形式的屏幕共享
stopVideoPreview() Future<int>
停止视频预览
subscribeAllRemoteAudio(bool subscribe) Future<int>
订阅/取消订阅所有用户音频(后续加入的用户也同样生效) [...]
subscribeRemoteAudio(int uid, bool subscribe) Future<int>
订阅/取消订阅指定用户音频流 [...]
subscribeRemoteSubStreamVideo(int uid, bool subscribe) Future<int>
订阅或取消订阅别人的辅流视频 [...]
subscribeRemoteVideo(int uid, int streamType, bool subscribe) Future<int>
订阅或取消订阅指定远端用户的视频流
toString() String
Returns a string representation of this object.
inherited
updateLiveStreamTask(NERtcLiveStreamTaskInfo taskInfo, UpdateLiveTaskCallback callback) Future<int>
更新修改房间推流任务。通话中有效。 taskInfo 直播任务信息 UpdateLiveTaskCallback 操作结果回调,方法调用成功才有回调
uploadSdkInfo() Future<int>
上传SDK日志信息 只能在加入频道后调用

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited