manju manju - 7 months ago 123
Android Question

How to capture the screen using /dev/graphics/fb0 (Android)

How to capture the Android device screen content using

and how to make it an image file using the collected data from frame buffer. I know for this it requires the device to be rooted and I am ok with that.

Thanks in advance,


This should work:

adb pull /dev/graphics/fb0 fb0
ffmpeg -vframes 1 -vcodec rawvideo -f rawvideo -pix_fmt rgb32 -s 320x480 -i fb0 -f image2 -vcodec png image.png