I want to play a video within a user specified time interval. I am using MPMoviePlayer
and my video is playing. Now I want to set the time frame that video should play. Let's say my video duration 5mins. when click on the video user can specify the time that how long he want to watch or listen. If he give 10minuts, my 5 mins video should play 10mins if he specify 2 mins, my 5 mins video should play only 2 mins.
How can I do this using MPMovieplayer
Please help me, thanks
How about using a timer to set the time that video should play. The code in swift version:
If the time bigger than the time of the video, you could just use the same timer concept to play the video again. But remember to stop it when time up.
Hope this solution could help you!