setCurrentDeviceMute method

Future<int?> setCurrentDeviceMute(
  1. int type,
  2. bool mute
)

设置当前设备是否静音

注意:此接口只支持Mac和Windows平台

参数:

type 设备类型,指定需要获取哪种设备的列表。详见TXMediaDeviceType定义,type 只支持 TXMediaDeviceTypeMic、TXMediaDeviceTypeSpeaker。

mute 是否静音/禁画

返回:

0:操作成功 负数:失败

Implementation

Future<int?> setCurrentDeviceMute(int type, bool mute
    ) async {
  var result = await _channel.invokeMethod('setCurrentDeviceMute', {
    "type": type,
    "mute": mute
  });
  return V2TXLiveFlutterResult.intValue(result);
}