iOS Catch recorded video and Upload
#1
Hi,

I'm shooting a video, and I can not see it after recording.
Below the code I capture the information of the house that pushes video:

Code:
- (vido)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info

{        

        NSString * moviePath = [[info objectForKey:UIImagePickerControllerMediaURL] path];
        if (UIVideoAtPathIsCompatibleWithSavedPhotosAlbum (moviePath)) {
            UISaveVideoAtPathToSavedPhotosAlbum (moviePath, nil, nil, nil);
        }

        [self dismissViewControllerAnimated:YES completion:^{

        Camera = YES;

}];

    //Save the movie
    VideoRecord = moviePath;
    NSLog(@"Video recorded: %@ - %@", info , moviePath);
}

-(IBAction)PlayVideo:(id)sender{

    NSString * filepath = [[NSBundle mainBundle] pathForResource:VideoRecord ofType:@"MOV"];
    NSURL * fileURL = [NSURL fileURLWithPath:filepath];

    

    moviePlayerController = [[MPMoviePlayerController alloc] initWithContentURL:fileURL];
    [moviePlayerController.view setFrame:CGRectMake(20, 76, 280, 199)];
    [self.view addSubview:moviePlayerController.view];
    //moviePlayerController.fullscreen = YES;
    [moviePlayerController play];

}

I created an IBAction to give the play the video that I recorded, but for some reason, the MPplayer only a black screen and not turning the video.

I also tried to return the video with [info objectForKey: UIImagePickerControllerMediaURL] , without the "path" as in the above code.
The way the video returns me with a "file :/ /", and thus, it generates an error and crashes the app.
Reply
#2
Can you clarify what this has to do with xbmc development please?
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much: click here
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
Reply

Logout Mark Read Team Forum Stats Members Help
Catch recorded video and Upload0