iphone - MPMoviePlayerController play video second time -
i need have possibility play more 1 video in app.
unfortunately, second time press play, video appears blinking.
i use code playing vide
nsurl *url = [[[nsurl alloc]initfileurlwithpath:[[nsbundle mainbundle]pathforresource:@"movie" oftype:@"m4v"]] autorelease];
mpmovieplayercontroller *mp = [[mpmovieplayercontroller alloc]initwithcontenturl:url];
mp.moviecontrolmode = mpmoviecontrolmodedefault;
[mp play];
movieplayer = mp;
[mp release];
can tell me can problem? in advance!
update 1: seems apple movieplayer example has same problem.
you can setting initial playback time -1.0 before calling play function
mp.initialplaybacktime = -1.0; put code before ur play method called.
Comments
Post a Comment