I have a quick question that I am using the following code to launch the camera and on iOS 4.x devices Record video, it works great. I want to use the same code on iPad 2 because the video recording feature of iPad 2 is. Will this work? Can anyone direct me?
if ([include the type: (id) kUTTypeMovie]) {UIImagePickerController * pickerController = [[[UIImagePickerController alloc] init] autorelease]; PickerController.delegate = self; PickerController.videoQuality = appDelegate.settingsCtrler.quality; PickerController.sourceType = UIImagePickerControllerSourceTypeCamera; PickerController.showsCameraControls = Yes; PickerController.mediaTypes = [NSArray arrayWithObject: (id) kUTTypeMovie]; PickerController.videoMaximumDuration = MaxDiscine; [Hide the floatingbar to hide the app]; [Self-Present Model View Controller: Picker Controller Animated: Yes]; } Thank you in advance!
If it's iOS 4.3 you should be ok - though I do not have iPad 2 to test it . I wrap a test in logic:
If ([Picker is sorterotype available: UIImagePickerControllerSourceTypeCamera]) {// Your code is here} So do not try to present the camera when no one is available.
Comments
Post a Comment