ios - How to show .srt/subtitle file in MPmovieviewController -
i working on mpmovieviewcontroller player showing video in app need show .srt
i have used below code
if(self.liveplayer) { [self.liveplayer.view removefromsuperview]; [self.liveplayer stop]; self.liveplayer=nil; } self.liveplayer = [[mpmovieplayercontroller alloc] init]; [self.view addsubview:self.liveplayer.view]; self.liveplayer.view.frame = cgrectmake(5.0, 64.0, [[uiscreen mainscreen] bounds].size.width - 10.0, viwvideo.frame.size.height - 10.0); self.liveplayer.view.autoresizingmask=uiviewautoresizingflexiblewidth; [self.liveplayer.view settranslatesautoresizingmaskintoconstraints:true]; self.liveplayer.controlstyle = mpmoviecontrolstyledefault; self.liveplayer.moviesourcetype = mpmoviesourcetypestreaming; self.liveplayer.shouldautoplay = no; frame = self.liveplayer.view.frame;
Comments
Post a Comment