I am using MPMovieplayercontroller
to play video it plays the video which comes from web services. Source video file was taken in potrait mode but it has been rotated 90º in anti-clockwise direction. So when i am playing it in MPMovieplayercontroller it is playing like following format attached is the sample image
Is there any way to rotate the video file which comes from web service?
I have tried to apply transform for MPMovieplayercontroller.view
but movie player controls also rotating. my requirement is i would need to rotate the video part only. Is there any way to achieve this. Please help me out to fix this it would be great help.
Thanks in advance
try with this: (I have made a subclass for MPMoviePlayerViewController)
- (void)configureSubViews
{
if (self.moviePlayer.view.subviews.count > 0)
{
UIView *view = self.moviePlayer.view.subviews[0];
if (view.subviews.count > 0)
{
UIView *sView = view.subviews[0];
self.viewPlayerVideoContent = [sView viewWithTag:1002];
self.viewPlayerControls = [sView viewWithTag:1003];
}
}
}
I don't really like to work in that way with the subViews, but it works.. (at least for iOS5 and iOS6)
then, you could try to rotate the viewPlayersVideoContent :)