setPoster method

Future setPoster(
  1. float posterTime
)

{zh} @brief 设置视频自动抽帧时间点,单位为秒。设置成功后,上传 SDK 将根据您设置的固定时间点截取视频帧,作为视频的封面图。

Implementation

Future setPoster(float posterTime) async {
  $a() => ($instance as $p_a.BDVideoUploader).setPoster(posterTime);
  $i() => {($instance as $p_i.BDVideoUploaderClient).snapshot = posterTime};

  if (Platform.isAndroid) {
    return $a();
  } else if (Platform.isIOS) {
    return $i();
  } else {
    throw UnsupportedError(
      'Not Support Platform ${Platform.operatingSystem}',
    );
  }
}