onAudioPlaybackDeviceTestVolume method
@detail callback
@author dixing
@brief Notification on the playing volume during the test for the local audio devices
@param volume Playing volume during the test for the local audio devices. The range is 0,255.
@note Start an audio-device test by calling startAudioPlaybackDeviceTest{@link #IRTCAudioDeviceManager#startAudioPlaybackDeviceTest} or startAudioDeviceRecordTest{@link #IRTCAudioDeviceManager#startAudioDeviceRecordTest} will register this callback for regular notification on playing volume. You can set the time interval between each callback by passing a proper value when calling the API above.
Implementation
FutureOr<void> onAudioPlaybackDeviceTestVolume(dynamic volume) async {
if ($instance == null || $instance is! IRTCEngineEventHandler) {
return;
}
return ($instance as IRTCEngineEventHandler)
.onAudioPlaybackDeviceTestVolume
?.call(int.tryParse(volume.toString()) ?? 0);
}