Im developing a camera app which uses SurfaceView for display.
I’m able to take screenshot of the SurfaceView (and save it as a bitmap)
with getDrawingCache() (on a layout which wraps the SurfaceView)
and also with canvas.drawBitmap(…)
however in both ways, the bitmap is always transparent/blank.
I have galaxy S3 and I can see that they have that feature in their camera
how exactly they do it?
thanks!
Well after hours, I got a nice solution for that.
Maybe it isn’t the best way, but it is good enough for me.
First get a start time right after the media recorder starts:
Then, when u press on the screen/button for taking screenshot, save the period:
Finally, when you stop recording, get the bitmap using the period and the Media retriever:
Hope it helps you!