Task to accomplish: Multiple shots in fractions of a second, at least 2 photos in 1 second.
Tried (for 2 photos): 1) Calling two takePicture(....) method simultaneously/loop, but the app crashes. 2) Calling the first takePicture(..) method and then other takePicture(..) method in onPictureTaken(..). This works but it is too slow. The time difference between these two shot is around 1 second which is not a preferable result for my app.
Question: How is it possible to take multiple shots, with a time difference of just some milliseconds?
(I'm working on android 2.3.3). Thanks in advance!
I used the callback function setOneShotPreviewCallback (Camera.PreviewCallback cb) and solved the problem. This grabs a single preview frame and let you use the frame as an image after converting into some usable format (RGB). Since, android supports 20-30 frames per second depending on the device, you can take several frames in fraction of seconds.