Skip to content

Instantly share code, notes, and snippets.

@sco
Created September 19, 2012 06:40
Show Gist options
  • Save sco/3748039 to your computer and use it in GitHub Desktop.
Save sco/3748039 to your computer and use it in GitHub Desktop.
- (void)importVideo
{
NSString *path = [[NSBundle mainBundle] pathForResource:@"sample" ofType:@"m4v"];
UISaveVideoAtPathToSavedPhotosAlbum(path, self, @selector(video:didFinishSavingWithError:contextInfo:), nil);
}
- (void)video:(NSString *)videoPath didFinishSavingWithError:(NSError *)error contextInfo:(void *)contextInfo
{
if (error != nil) {
NSLog(@"Error: %@", error);
} else {
NSLog(@"Saved video");
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment