如题,也就是seek 我设置setCurrentPlaybackTime 是不好使的
call seek when prepared.
我想切换URL的时候同时切换到上次播放视频的位置,我的代码是这样的 我想知道这样做哪里不对
//移除上一个view
[_player shutdown];
[_player.view removeFromSuperview];
if (_player != nil) {
_player = nil;
}
//新建一个新的view
[IJKMediaModule sharedModule].appIdleTimerDisabled = YES;
[IJKFFMoviePlayerController checkIfFFmpegVersionMatch:YES];
IJKFFOptions * options = [IJKFFOptions optionsByDefault];
[options setFormatOptionValue:@"ijktcphook" forKey:@"http-tcp-hook"];
NSURL *theMovieURL = [NSURL fileURLWithPath:path];
self.player = [[IJKFFMoviePlayerController alloc] initWithContentURL:theMovieURL withOptions:options];
self.player.scalingMode = IJKMPMovieScalingModeAspectFit;
self.player.shouldAutoplay = YES;
[self.view addSubview:_player.view];
[self.player prepareToPlay];
//设置seek的时间 这个时间算是prepare之后的设置时间吗?
[self.player setCurrentPlaybackTime:10.0];
IJKMPMediaPlaybackIsPreparedToPlayDidChangeNotification
thanks to your reply , I also noticed that notification,I can set current time under this change,once again thank you for your reply .
你好 这个问题解决了吗,JKFFMoviePlayerController里没setCurrentPlaybackTime这个方法
我也是用currentPlaybackTime,seek回来后会有问题,会往回跳秒
seek 后是从最近的关键帧开始播放
2017-04-14 15:04 GMT+08:00 aipaiSpaceMan notifications@github.com:
我也是用currentPlaybackTime,seek回来后会有问题,会往回跳秒
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/Bilibili/ijkplayer/issues/2275#issuecomment-294103946,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AEOmliKmmWjNEfU7t9n6BujeLgs8eFVEks5rvxpogaJpZM4KzURt
.
@raymond1012 如何能让播放器seek到当前帧而不是关键帧呢?多等一会儿也可以,谢谢啦
[options setPlayerOptionIntValue:1 forKey:@"enable-accurate-seek"];
我也是用currentPlaybackTime,seek回来后会有问题,会往回跳秒
解决了吗
Most helpful comment
[options setPlayerOptionIntValue:1 forKey:@"enable-accurate-seek"];