mpmovieplayercontroller

Assertion failure: movie player has wrong activation state (1)

我只是一个虾纸丫 提交于 2020-01-03 09:54:25
问题 I am playing a video (m4v) in an iPad app on one page, then it goes to a different View Controller which plays another video. It plays fine, but when the second video finishes playing it then throws an Assertion failure. The error is: *** Assertion failure in -[MPMoviePlayerControllerNew _moviePlayerDidBecomeActiveNotification:], /SourceCache/MobileMusicPlayer_Sim/MobileMusicPlayer-1137.39/SDK/MPMoviePlayerController.m:1236 *** Terminating app due to uncaught exception

iOS 8 video progress bar not visible

微笑、不失礼 提交于 2020-01-02 13:45:10
问题 I have an iOS app in which I am trying to show videos using MPMoviePlayerController . The code is very simple and working fine on all the devices with all iOS version greater than 6.0. But the problem is on iOS 8 and 8.1, the progress bar of the video is not visible as shown in below image. I dont understand why this is happening or is this iOS 8 bug. Please suggest. Thanks in advance. 回答1: I had this issue too in my app, which supports several iOS versions but this issue is indeed only

Asynchronous MPMoviePlayerController load has no duration value

丶灬走出姿态 提交于 2020-01-02 08:08:49
问题 I assume that the initWithContentURL: method is not asynchronous. I added the following methods to do the load in the background and then assign the temporary player to my variable. -(void)createPlayer { NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; MPMoviePlayerController *temp = [[MPMoviePlayerController alloc] initWithContentURL:[NSURL URLWithString:@"URLString"]]; [self performSelectorOnMainThread:@selector(passPlayer:) withObject:temp waitUntilDone:YES]; [temp release];

iPhone MPMoviePlayerController : download files while streaming en play them locally

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-02 06:11:21
问题 I've m3u8 file with all the TS files. MPMoviePlayerController play them fine via http request on the streaming server. But I'd like to get the files locally in order to play them again later without any connection. I managed to download m3u8 file and all the TS files locally on my device, I edited m3u8 files to point to local .ts instead of http ones, but I can't read them from this emplacement. (VLC can do it well) Is there a way to download the segments while playing (to avoid 2 downloads)

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

Generating thumbnail from video - ios7

天大地大妈咪最大 提交于 2020-01-01 05:29:31
问题 I am using this for reference: Getting thumbnail from a video url or data in IPhone SDK The method is using the MPMoviePlayerController class instead of the AVFoundation, and I think I want to use that as well because the people said that MPMoviePlayer way is faster than the AVFoundation way. The problem is, the method used to create the thumbnails, [player thumbnailImageAtTime:1.0 timeOption:MPMovieTimeOptionNearestKeyFrame] is deprecated in iOS 7.0. By looking at the apple docs, the

MPMoviePlayerController does not work with movie in documents folder

醉酒当歌 提交于 2020-01-01 03:47:25
问题 I have a ViewController which plays a movie. If the movie was downloaded (with ASI-HTTP-Request) it takes the local version. Otherwise it streams it from the web. It's the exact same movie. Streaming does work very well, but playing the local file does not work. Just a black screen and no controls. The file has been downloaded correctly I checked the md5 checksum. It's a Apple QuickTime Video (.mov) at a size of 1024x5xx pixel. player = [[MPMoviePlayerController alloc] init]; [player.view

Is it possible to mute MPMoviePlayerController?

最后都变了- 提交于 2020-01-01 00:27:12
问题 In my iPhone application I want to mute & unmute MPMoviePlayerController. I have searched a lot but I am unable to succeed. Is it possible to mute audio in MPMoviePlayer controller? Please help me out. Thanks in advance. 回答1: [[MPMusicPlayerController applicationMusicPlayer] setVolume:0]; This Line will mute the sound(hopefully)..:) 回答2: Use this to mute. NSError *error; if ( ![[AVAudioSession sharedInstance] setActive:NO error:&error] ) { NSLog(@"Error encountered: %@", [error

Getting Timed Metadata in Swift ios 8 From M3U8 Streaming Video

守給你的承諾、 提交于 2019-12-31 18:17:14
问题 I'm trying to duplicate this https://jmacmullin.wordpress.com/2010/11/03/adding-meta-data-to-video-in-ios/ in swift. Here is a video of Jake's code in action... Objective C Timed Metadat in HLS stream Here is an additional link to something similar... http://cloudfields.net/blog/metadata-audiostream-mpmovieplayercontroller/ When my video is playing timed metadata should update a button to redirect to a specific youtube url in a webview when clicked. My video is roughly 15 min long and has 6

MPMoviePlayerController alternatives on iPhone?

旧巷老猫 提交于 2019-12-31 10:36:19
问题 I am looking for alternatives to the MPMoviePlayerController on the iPhone. As a video player its functionality is very limited. According to the class reference there is no way to get the current play back time or set a new time, for example. It's just play and stop. Are there any middleware solutions out there for iPhone video playback that offer more functionality? CRI has something in development but it has not been released. I haven't been able to find anything else. Thanks. 回答1: Keep in