views:

28

answers:

1

I am new to iphone development.I have created a application which able to play a video from a url.Is there any animation can be set for opening of the video player in iphone?.The video is opened normally in landscape view. I want to show the opening of video player with some animation.Is there any way out?

  NSURL *movieURL = [NSURL URLWithString:@"http://url of movie"];

if (movieURL)
{
    if ([movieURL scheme])  
    {
        MovietryAppDelegate *appDelegate = (MovietryAppDelegate *)[[UIApplication sharedApplication] delegate];

        [appDelegate initAndPlayMovie:movieURL];
    }
}

In the delegate class i have defined the initAndPlayMovie method.I used the Apple sample "movie player " for my reference.Thanks.

A: 

I guess you can create an UIImageView, and place a screenshot of the movie player on it. Then you can do some fancy effects by scaling the image view or changing its opacity. It may look like "opening".

After the movie is loaded, you will receive, MPMoviePlayerContentPreloadDidFinishNotification and now you can remove the image view.

zonble