mpmovieplayer

MPMoviePlayerController showing black screen with sound in iOS 7, works fine in iOS 6

ⅰ亾dé卋堺 提交于 2020-01-13 11:04:41
问题 //introVideoViewController #import <AVFoundation/AVAudioSession.h> #import <AudioToolbox/AudioServices.h> #import <AVFoundation/AVAudioPlayer.h> #import <MediaPlayer/MediaPlayer.h> @property(nonatomic,strong) MPMoviePlayerController *playercontroller; Hi Guys, anybody know what in iOS 7 i can heard my video sound but not the video, it works fine in iOS 6. any comments are greatly appreciated. //introVideoViewController //prepare & init video -(void)prepareIntroVideo { NSURL *url = [NSURL

MPMoviePlayerController showing black screen with sound in iOS 7, works fine in iOS 6

别等时光非礼了梦想. 提交于 2020-01-13 11:04:28
问题 //introVideoViewController #import <AVFoundation/AVAudioSession.h> #import <AudioToolbox/AudioServices.h> #import <AVFoundation/AVAudioPlayer.h> #import <MediaPlayer/MediaPlayer.h> @property(nonatomic,strong) MPMoviePlayerController *playercontroller; Hi Guys, anybody know what in iOS 7 i can heard my video sound but not the video, it works fine in iOS 6. any comments are greatly appreciated. //introVideoViewController //prepare & init video -(void)prepareIntroVideo { NSURL *url = [NSURL

MPMoviePlayer in iOS 9

两盒软妹~` 提交于 2020-01-10 04:47:16
问题 i have made a function in iOS 8 to play a movie in the background and now when i want to use it in iOS 9 it gives me a warning and says that it best not to use MPMoviePlayer and instead use AVPlayer. but i don't know anything about AVPlayer. how can i convert this to a proper function without warning that uses AVPlayer instead of MPMoviePlayer? heres the func : func playVideo() ->Bool { let path = NSBundle.mainBundle().pathForResource("video", ofType:"mov") //take path of video let url =

MPMoviePlayerController shows blank white screen before launch?

二次信任 提交于 2020-01-02 05:29:06
问题 I have an MPMoviePlayerController that I am presenting modally. The video loads fine, however just before the video is launched the screen turns white until it has loaded. How can I prevent this from happening? moviePlayerViewController = [[MPMoviePlayerViewController alloc] initWithContentURL:[NSURL URLWithString:mySTVideo.video_url]]; [self presentModalViewController:moviePlayerViewController animated:YES]; 回答1: First, you should be using this for display the movies: [self

How to output video on external display with controls on ipad?

本秂侑毒 提交于 2020-01-01 07:09:06
问题 Currently when outputting video to an external display from the iPad, it moves the controls and all to the external display. This is not useful because you cannot control the movie while the controls are on the external display. Here are some code snippets from our app. This is the screen setup code: (A method called setupExternalScreen) if ([[UIScreen screens] count] > 1) { external_disp = [[UIScreen screens] objectAtIndex:1]; [external_disp setCurrentMode:[[external_disp availableModes]

Dismiss MPMoviePlayerViewController on play error

只谈情不闲聊 提交于 2019-12-30 05:14:05
问题 I have a problem with the MPMoviePlayerViewController: If the controller can't find the movie at the specified URL it displays a white screen and I can't make it go close. This is how I start the movie player: - (void) playVideo:(NSString*)path { NSURL* url = [NSURL URLWithString:path]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayBackDidFinish:) name:MPMoviePlayerPlaybackDidFinishNotification object:nil]; double osversion = [[[UIDevice currentDevice]

MPMoviePlayerViewController setCurrentPlaybackTime goes to the wrong position

你。 提交于 2019-12-24 08:14:01
问题 I have an application where I play a video in the background, the process is very simple, the same behavior is repeated endlessly. On a user gesture the movie is played for a couple of seconds and paused, The application works perfectly as long as the suer didn't press the home button. when the application comes from the back-ground to the front-ground the video turns all black till the user makes a gesture. In order to resolve the black screen problem, I shared the player object, then in

iOS - login view before uitabbarcontroller

﹥>﹥吖頭↗ 提交于 2019-12-24 07:32:22
问题 I want to display interface UITabBar when login succeeds. I declare interface UITabBar in AppDelegate , but after login success I don't know how to call the interface. Here is my code: appdelegate.m -(void)loadInterface { [self configureiPhoneTabBar]; } -(void)configureiPhoneTabBar { UITabBarController *tabBarController = (UITabBarController *)self.window.rootViewController; UIViewController *controller1 = [[tabBarController viewControllers] objectAtIndex:0]; [self

iOS - login view before uitabbarcontroller

我只是一个虾纸丫 提交于 2019-12-24 07:32:12
问题 I want to display interface UITabBar when login succeeds. I declare interface UITabBar in AppDelegate , but after login success I don't know how to call the interface. Here is my code: appdelegate.m -(void)loadInterface { [self configureiPhoneTabBar]; } -(void)configureiPhoneTabBar { UITabBarController *tabBarController = (UITabBarController *)self.window.rootViewController; UIViewController *controller1 = [[tabBarController viewControllers] objectAtIndex:0]; [self

How do I catch the MPMoviePlayer next button click event while in fullscreen mode on the iPad?

≡放荡痞女 提交于 2019-12-21 06:18:43
问题 When the MPMoviePlayerViewController is in fullscreen mode on the iPad, it defaults to having its controls to have a previous and next button on the overlay there. In my project I need to capture the click for that overlay button and handle it accordingly. Since I'm not sure how to invoke a playlist just yet there is no next item and clicking on the button breaks the view once I exit fullscreen mode. Somehow it just doesn't know what to do and I get no errors. What I would like to know is if