0

I am using MPMoviePlayerViewController for playing the sound and video. I am streaming the song from the url. It is working fine.But the problem is, MPMoviePlayerViewController is not showing the time progress for the song I playing. That bar is disabled. How to make the time progress bar active? I have following code to play the song.

    mediaPlayerController = [[MPMoviePlayerViewController alloc] initWithContentURL:songUrl];
    [self presentModalViewController:mediaPlayerController animated:YES];
    [[mediaPlayerController moviePlayer] play];

enter image description here

V-Xtreme
  • 7,230
  • 9
  • 39
  • 79

2 Answers2

0

If you want to show the current progress time on your own custom way, you can show it by using the currentPlaybackTime property in the MPMediaPlayback protocol gives you that info.

Hemang
  • 26,840
  • 19
  • 119
  • 186
0

U use AVPlayer for playing live streaming. Refer this link.

Also refer StitchedStreamPlayer link sample code by apple.


Set controlStyle for mediaPlayerController:

  [mediaPlayerController moviePlayer].controlStyle = MPMovieControlStyleFullscreen
Community
  • 1
  • 1
Paresh Navadiya
  • 38,095
  • 11
  • 81
  • 132