I'm trying to implement burst mode on android's camera (currently on ICS) I've searched over the net trying to find some documentation about this features and encounter with several issues:
Need to save (probably on asynctask) every captured image values and afterwards process it and save it in sd card
Probably handle the heap while capturing images in continuous mode
So far that's the first impression I got when investigating this issue, Can someone guide me where can I get more information, algorithms maybe or even source code for example?
Thanks for the help. Udi
You may also check this code as a baseline: https://github.com/rdasxy/android-burst-camera .
Also check this first: http://developer.android.com/guide/topics/media/camera.html.
For your preview use TextureView
(you need to add hardware accelleration to your AndroidManifest.xml) instead of SurfaceView
.
You might run out of heap quite fast if you try to cache the pictures in memory, especially if you set the picture size to a large value. Thus, save the data as soon as you receive it in method pictureCallBack.onPictureTaken
by using e.g. an AsynchTask. Check (measure!) the write speed of your device's internal memory in contrast to the sdcard write speed. You might get higher overall process performance when saving to the device's internal memory first and move it to sdcard later if required. Also try to motivate the android system to provide you larger heap size by adding largeHeap=true
to your AndroidManifest.xml
This question is somewhat similar to this question on stack overflow. The code in that question could help.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With