Capture Video in iPhone

Posted by Timmi on Stack Overflow See other posts from Stack Overflow or by Timmi
Published on 2010-04-12T09:47:48Z Indexed on 2010/04/12 9:53 UTC
Read the original article Hit count: 163

Filed under:

Hi,

I used the following code to record video.

    UIImagePickerController *m_objpicker;=[[UIImagePickerController alloc] init];
    m_objpicker.sourceType = UIImagePickerControllerSourceTypeCamera;           

    m_objpicker.mediaTypes = [NSArray arrayWithObject:(NSString *)kUTTypeMovie];

    // hide the camera controls
    //picker.showsCameraControls=NO;
    m_objpicker.delegate = self;
    //picker.allowsImageEditing = NO;
    m_objpicker.allowsEditing=NO;
    // and put our overlay view in
    //picker.cameraOverlayView=m_objOverlayView;
    [self presentModalViewController:m_objpicker animated:YES]; 

When we finish recording

  • (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info{

    NSURL *m_objMediaURL=[info objectForKey:UIImagePickerControllerMediaURL];

    [m_objpicker dismissModalViewControllerAnimated:YES];

}

My doubt is, how to save the captured video to a location we specify. Also how to use UISaveVideoAtPathToSavedPhotosAlbum .

What all things i need to change in my code so that i can save video to a specified location

Thanks,

© Stack Overflow or respective owner

Related posts about iphone