How to automatically capture images as user moves down the iphone /ipad camera to make a panoroma like picture?
I have an app where i scan the forms means i take its pictures and upload them . Now if the form is long so that the iphone /ipad camera could not take picture of entire form clearly. In that case i want the user to slowly move the camera down , so that continous images are taken until the whole form is looked or scanned . After that create a picture stitching all the frames together. I know there can be various ways of doing this manually like i can let user chose when to take pictures ad after merge them together.
But is there any way to do this automatically maybe some api etc. I mean automatically capture frames as user moves the camera down. After that i can merge the images together .
I think you should capture video (the UIImagePickerController gives you a quick generic interface for this), then use MPMoviePlayerController to get images from the captured video.
MPMoviePlayerController provides requestThumbnailImagesAtTimes:timeOption:.
- write down the start time start = [NSDate date];
- ask the user to pan over the document and to press the stop button when done (you can put some instruction right on the preview view using the cameraOverlayView property
- bring up the picker and startVideoCapture
when imagePickerController:didFinishPickingMediaWithInfo: gets fired, write down the end time.
then, based on the interval between start and end, pick N times for images
- build an MPMoviePlayerController and call requestThumbnailImagesAtTimes:timeOption:
You'll have N images to stitch.