Q:

capture image from camera automatically after sometime via coding

I want to know that is it possible to capture image from the camera automatically after some time delay i.e setting some user defined timer. So when the timer goes to Zero than the iphone/ipad's camera should capture image.
I know how to open camera and capture image when user click on capture button and save it to photo library but dont have any idea about setting timer. 
Is it possible ?
Please help me with some links or any reference if it is possible to do.

A:

UIImagePickerController has a takePicture method that can be called programmatically.
https://developer.apple.com/library/ios/documentation/uikit/reference/UIImagePickerController_Class/UIImagePickerController/UIImagePickerController.html
https://stackoverflow.com/a/4477542/2695503

