startRecordingRemoteData method

Future<void> startRecordingRemoteData(
  1. ZegoDataRecordConfig config,
  2. String streamID
)

Starts to record and directly save the data to a file.

Available since: 3.21.0 Description: Start remote streaming recording and save the audio-video data directly to local files. The recorded data will be identical to the streamed data. Restrictions: None. Caution: Developers should not stopPlayingStream during recording, otherwise the SDK will end the current recording task. The data of the media player needs to be mixed into the publishing stream to be recorded. Related callbacks: Developers will receive the onRemoteDataRecordStateUpdate and the onRemoteDataRecordProgressUpdate callback after start recording.

  • config Record config.
  • streamID play stream id.

Implementation

Future<void> startRecordingRemoteData(
    ZegoDataRecordConfig config, String streamID) async {
  return await ZegoExpressImpl.instance
      .startRecordingRemoteData(config, streamID);
}