I saw the following link for the above query but both the answers does not met the expectation.
[How to programmatically take a screenshot in Android?
Expectation: Capture camera preview with overlay.
I saw the following link for the above query but both the answers does not met the expectation.
[How to programmatically take a screenshot in Android?
Expectation: Capture camera preview with overlay.
I provided solution to a folk, please check this answer. He had trouble to get the result but copied code below is what I'm using in production since a year ago. please try it.
The code captures image in
SurfaceView
which is given fromCamera
. You can overlay some views on it. They will be captured along with Camera preview.