snapshotVideo method

  1. @override
void snapshotVideo(
  1. String userId,
  2. TRTCVideoStreamType streamType,
  3. TRTCSnapshotSourceType sourceType, {
  4. String? path,
})
override

Screencapture video(Only supports Windows)

You can use this API to screencapture the local video image or the primary stream image and substream (screen sharing) image of a remote user.

Parameters:

Note: On Windows, only video image from the TRTCSnapshotSourceType.stream source can be screencaptured currently.

Implementation

@override
void snapshotVideo(String userId, TRTCVideoStreamType streamType, TRTCSnapshotSourceType sourceType, {String? path}) {
  if (Platform.isWindows || Platform.isMacOS) {
    TRTCLog(_tag, "snapshotVideo is not currently supported on this platform");
    return;
  }
  TRTCLog(_tag, "snapshotVideo: $userId $streamType $sourceType");
  TRTCMethodChannel().snapshotVideo(userId, streamType, sourceType, path ?? "");
}