iOS AVPlayer seekToTime 播放时间不准确

2020-10-12  本文已影响0人  东方诗空

解决方案:

int32_t timeScale = self.player.currentItem.asset.duration.timescale;
CMTime time = CMTimeMakeWithSeconds(77.000000, timeScale);
[self.player seekToTime:time toleranceBefore:kCMTimeZero toleranceAfter:kCMTimeZero];

参考文档

上一篇下一篇

猜你喜欢

热点阅读