I have mp3
and mp4
dat in url. I tried to play that in my ViewController
so, i have created two players
audioPlayer = [[MPMoviePlayerController alloc]init];
videoPlayer = [[MPMoviePlayerController alloc]init];
and assigned those links to the players -
Video
videoPlayer.contentURL = [NSURL URLWithString:video];
[videoPlayer prepareToPlay];
Audio
audioPlayer.contentURL = [NSURL URLWithString:audio];
[audioPlayer prepareToPlay];
Here i'm facing one issue that i can able to play one of them from above. It won't play either one is stopped after playing or initially its not allow to play both of them.
How do i fix this.