我做了
player.shouldAutoplay = YES;
[player setEndPlaybackTime:initPlay];
它工作正常,然后在
- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event{
if ([touches count] == 1) {
[player play];
}
}
即使触摸发生并且播放命令发生也不起作用,但如果我尝试再次设置setEndPlaybackTime,那么stil不会播放?我只是希望它在用户触摸屏幕之后继续播放任何想法?
答案 0 :(得分:0)
视频是否必须重绕到开头?你试过了吗?
- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event{
if ([touches count] == 1) {
player.initialPlaybackTime = 0.0;
[player play];
}
}
值为-1也可能有效。