How to take screenshoots over EGLFS - for raspberryPi
It was a bit frustrating at the beginning not found a simple way to get application screenshots over EGL/OpenGL ES. However, the magic of altruism and open-source gave us an alternative - thanks Andrew Duncan (https://github.com/AndrewFromMelbourne).
This project was figure out by a work colleague when we needed a long time ago to build a manual with software screens.
The drawback is that solution is restricted to raspberryPI.
Requirements
-
sudo apt-get install libpng12-dev
-
(as root) curl -sL https://raw.githubusercontent.com/AndrewFromMelbourne/raspi2png/master/installer.sh | bash -
Usage
raspi2png
The result is a file called snapshot.png. However you can indicate a name using -p param:
raspi2png -p nome.png
More options:
Usage: raspi2png [–pngname name] [–width ] [–height ] [–compression ] [–delay ] [–display ] [–stdout] [–help]
–pngname,-p - name of png file to create (default is snapshot.png)
–height,-h - image height (default is screen height)
–width,-w - image width (default is screen width)
–compression,-c - PNG compression level (0 - 9)
–delay,-d - delay in seconds (default 0)
–display,-D - Raspberry Pi display number (default 0)
–stdout,-s - write file to stdout
–help,-H - print this usage information
Peace!