From ac844cfac007dab4fa2d58dc0b8446883e6fd308 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B1=9F=E6=88=98?= <40414978+PatriceJiang@users.noreply.github.com> Date: Mon, 28 Sep 2020 09:53:59 +0800 Subject: [PATCH] fix ios video seekTo inaccuratefix ios video seekTo inaccurate #2531 (#2838) --- native/cocos/ui/videoplayer/VideoPlayer-ios.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/native/cocos/ui/videoplayer/VideoPlayer-ios.mm b/native/cocos/ui/videoplayer/VideoPlayer-ios.mm index f84b95f687..a17a72253b 100644 --- a/native/cocos/ui/videoplayer/VideoPlayer-ios.mm +++ b/native/cocos/ui/videoplayer/VideoPlayer-ios.mm @@ -156,7 +156,7 @@ typedef NS_ENUM(NSInteger, PlayerbackState) { -(void) seekTo:(float)sec { if (self.playerController.player) - [self.playerController.player seekToTime:CMTimeMake(sec, 1)]; + [self.playerController.player seekToTime:CMTimeMake(sec * 600, 600) toleranceBefore:kCMTimeZero toleranceAfter:kCMTimeZero]; } -(float) currentTime