MPMoviePlayerController, Video is flickering upon second play back.

Discussion in 'iOS Programming' started by CorporateFelon, Jun 24, 2009.

  1. CorporateFelon macrumors regular


    Oct 26, 2007
    Boston, MA
    I'm using MPMoviePlayerController to play video, and its playing perfectly fine initially. However when I play the same movie again the video flickers. Yet If I play video A, then play video B, then play video A again the play back is normal. It is just when I play video A, then video A again that this happens.

    I'm using the follow code to initiate the play back.

    MPMoviePlayerController *theMovie=[[MPMoviePlayerController alloc] initWithContentURL:[NSURL URLWithString: movieLocation]];
    [[NSNotificationCenter defaultCenter] addObserver:self  selector:@selector(myMovieFinishedCallback:) name:MPMoviePlayerPlaybackDidFinishNotification object:theMovie]; 
    [theMovie play]; 
    And the following is called when the movie finished its playback.
        MPMoviePlayerController* theMovie=[aNotification object]; 
        [[NSNotificationCenter defaultCenter] removeObserver:self name:MPMoviePlayerPlaybackDidFinishNotification object:theMovie]; 
        [theMovie release]; 
    If any one can point me in some direction as to why this is happening, or what I can do to fix it, it would be greatly appreciated.
  2. marcalanjones macrumors newbie

    Jun 26, 2009
    Did you get this issue resolved? I am having the same problem.

  3. CorporateFelon thread starter macrumors regular


    Oct 26, 2007
    Boston, MA
    Not yet. When I finish some other functionality I'll take a look at my problem again. At the moment I've only tested on the simulator, and not on a device yet. At the moment I'm really hoping its just something buggy with the simulator.
  4. Joined:
    Jul 1, 2009
    Did you ever figure out why the movie would flicker and...

    Did you ever figure out why the movie would flicker and how to fix it?
  5. sinisa macrumors newbie

    Oct 25, 2008
    Shanghai, China
    even Apple's MoviePlayer sample flickers

    I'm having same problem in Simulator, and haven't yet tried it on the device itself.

    When video is played for the first time, all is fine. As soon as I want to replay it, flickering appears, some times more severe, some times less.

    I've used exactly the same code as shown above in this thread.

    I've tried Apple's sample MoviePlayer, and, it flickers too when playing video again.

    Anyone found solution to this? Or is this just bug in Simulator?
  6. sneha macrumors newbie

    May 24, 2009
    I am also using MPMoviePlayer Controller to play videos .I am also having the same problem.:(:(
    I am having another problem when i tested on the device.

    I started playing video 1 and then stopped it and played video 2 then i repeated the same thing again nd again after sometime when my video 2 is playing i get frames from video 1...:confused::confused::confused:

    Its a very strange problem. Can any1 help me out with it???
  7. MacToddB macrumors 6502a


    Aug 21, 2007
    Rochester, NY
    I've seen this often on the simulator but never in the device and none of my customers has either. I vote simulator bug.

Share This Page