Hey, I know that when a user selects a Video I do get a URL for the video.... but can you direct me to a proper implementation because my App just sticks there when I click choose in the simulator and I cannot navigate away from the Video Player page.... Any good tutorial on this?
A:
Once you select the video - execution flows to the following function:
(void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info
{
.... code here .....
//get the videoURL NSString* videoURL= [info objectForKey:UIImagePickerControllerMediaURL];
//IMPORTANT: remember to test that the video is compatible for saving to the photos album
UISaveVideoAtPathToSavedPhotosAlbum(videoURL, self, @selector(video:didFinishSavingWithError:contextInfo:), nil);
.... code here .....
}
Take a look into 'UISaveVideoAtPathToSavedPhotosAlbum' specifically. This allows saving to the camera roll.
Lance
2010-07-21 07:09:29
Please flag this as the correct answer: this place is give and take.
Lance
2010-07-28 21:58:53