User avatar
Bigcat123
Posts: 230
Joined: Thu Aug 23, 2012 2:41 pm

Screenshot?

Fri Oct 05, 2012 6:08 am

Dear Raspbian developers,

What is the easiest way to get a screenshot of my Raspberry Pi? Do I have to SSH it? Does 'control + alt + print screen' work?

Thanks a million! ;)
Just a beginner sharing his experiences on his way to geek nirvana...

User avatar
joan
Posts: 13365
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Screenshot?

Fri Oct 05, 2012 8:06 am

If you have X running on the Pi (the graphical user interface) you can use

DISPLAY=":0.0"; export DISPLAY; import -window root screenshot.png

from ssh or locally I assume.

import is part of the imagemagick suite.

If it's not on your Pi you'd need to

sudo apt-get install imagemagick

User avatar
joan
Posts: 13365
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Screenshot?

Fri Oct 05, 2012 8:11 am

If you have a keyboard connected just press the print screen key (whatever that is on your keyboard). I run my Pi without keyboard so don't know if it works or not.

User avatar
Bigcat123
Posts: 230
Joined: Thu Aug 23, 2012 2:41 pm

Re: Screenshot?

Fri Oct 05, 2012 3:15 pm

Sorry but either of those DIDN'T work for me... Anyone know any other ways to get a screenshot of your Pi? Please Someone help me! Thanks for trying though Joan!

;)
Just a beginner sharing his experiences on his way to geek nirvana...

User avatar
scruss
Posts: 1674
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Screenshot?

Fri Oct 05, 2012 3:27 pm

I use the distressingly-named utility 'scrot'. To get a shot of the active window, I use:

Code: Select all

sleep 5; scrot -bu
The five second delay gives you a chance to get the window in order. It has options to take the whole screen (root window in X jargon).

If you're using a remote X session through ssh, use whatever screenshot program is on the host.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.

cyanarnofsky
Posts: 70
Joined: Tue Jul 31, 2012 11:33 pm

Re: Screenshot?

Wed Jan 16, 2013 7:24 pm

So I have a modified version of screenly going, so a uzbl browser is running, is there a simple way like

DISPLAY=":0.0"; export DISPLAY; import -window root screenshot.png

that would capture that browser window? I have tried the above command but gives me a blank black image. I assume I need to direct it at the uzbl window but I am new to this, is there a way to make it grab the top most window or active window through a basic import command like that. This is a remote system and I want to be able to verify with a screenshot what is running on the screen, which this is perfect for if I can get it to see the browser. Thanks!

cyanarnofsky
Posts: 70
Joined: Tue Jul 31, 2012 11:33 pm

Re: Screenshot?

Wed Jan 16, 2013 8:27 pm

found my answer, scrot is much better for terminal option, at least in my case.

anatak
Posts: 19
Joined: Mon Aug 18, 2014 5:00 am

Re: Screenshot?

Wed Aug 20, 2014 4:35 am

would you care to tell us your answer ?

blavery
Posts: 95
Joined: Sun Jul 01, 2012 2:57 am
Location: QLD. Australia

Re: Screenshot?

Wed Aug 20, 2014 5:25 am

I simply installed gnome-screenshot in the pi.

I have vnc installed too (XIIVNC), and I often control the pi from a linux laptop. Then it is easy to take the pi screenshot directly on the laptop. (That uses gnome-screenshot on the laptop!)

B.

User avatar
scruss
Posts: 1674
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Screenshot?

Mon Feb 27, 2017 2:04 pm

(tying up an old thread that still gets good search engine hits)

Under Raspbian/Pixel, the Print Screen key should save a PNG image of your desktop in your home folder. The configuration is defined in the file .config/openbox/lxde-pi-rc.xml, and by default it uses ‘scrot’.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.

User avatar
mwilliams03
Posts: 118
Joined: Mon Oct 29, 2012 2:56 pm
Contact: Website

Re: Screenshot?

Tue Feb 28, 2017 3:43 am

there is also fbcat. which will capture whatever is in the framebuffer
Mark -- OzzMaker.com -- Creator of PiScreen - A 3.5" TFT for the Rasspberry Pi and BerryIMU.

n67
Posts: 695
Joined: Mon Oct 30, 2017 4:55 pm

Re: Screenshot?

Fri Feb 23, 2018 12:50 am

mwilliams03 wrote:
Tue Feb 28, 2017 3:43 am
there is also fbcat. which will capture whatever is in the framebuffer
Just to be clear, fbcat is for screencapturing the text mode (virtual console), not the GUI (desktop).

There is a man page for it at:

https://www.unix.com/man-page/debian/1/fbcat/

There is also something called "fbgrab" (above URL, make the obvious change).

Note that fbcat takes the text contents of the virtual console, and "graphicalizes" it into a PPM file.

The PPM file can then be converted to any other graphics format (PNG, JPG, etc) using, e.g., ImageMagick's "convert" utility.
"L'enfer, c'est les autres"

User avatar
Laui
Posts: 57
Joined: Fri Mar 17, 2017 7:27 pm

Re: Screenshot?

Fri Feb 23, 2018 4:55 pm

not the easiest way, but the smartest way is to install a graphic editor/programm like 'pinta' or 'gimp'. They can Screenshots

User avatar
scruss
Posts: 1674
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Screenshot?

Sat Feb 24, 2018 2:10 am

AndrewFromMelbourne/raspi2png is pretty magic, too. Grabs the hardware framebuffer
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.

n67
Posts: 695
Joined: Mon Oct 30, 2017 4:55 pm

Re: Screenshot?

Sat Feb 24, 2018 9:51 am

scruss wrote:
Sat Feb 24, 2018 2:10 am
AndrewFromMelbourne/raspi2png is pretty magic, too. Grabs the hardware framebuffer
Seems to do about the same as scrot or, for that matter, display from ImageMagick.

Not that I am saying otherwise, mind you, but is there any particular reason to prefer Andrew's program over either of these?
"L'enfer, c'est les autres"

fruitoftheloom
Posts: 16610
Joined: Tue Mar 25, 2014 12:40 pm

Re: Screenshot?

Sat Feb 24, 2018 10:45 am

n67 wrote:
Sat Feb 24, 2018 9:51 am
scruss wrote:
Sat Feb 24, 2018 2:10 am
AndrewFromMelbourne/raspi2png is pretty magic, too. Grabs the hardware framebuffer
Seems to do about the same as scrot or, for that matter, display from ImageMagick.

Not that I am saying otherwise, mind you, but is there any particular reason to prefer Andrew's program over either of these?

No one appears to have mentioned Shutter which is in the repositories:

http://shutter-project.org/about/
Adieu

n67
Posts: 695
Joined: Mon Oct 30, 2017 4:55 pm

Re: Screenshot?

Sat Feb 24, 2018 11:13 am

No one appears to have mentioned Shutter which is in the repositories:
Which, yet again, begs the question "Why?"

Unless you give some kind of justification - some kind of reason for wanting something other than 'scrot' (which is installed by default), nobody's going to go chasing a URL.
"L'enfer, c'est les autres"

fruitoftheloom
Posts: 16610
Joined: Tue Mar 25, 2014 12:40 pm

Re: Screenshot?

Sat Feb 24, 2018 7:40 pm

n67 wrote:
Sat Feb 24, 2018 11:13 am
No one appears to have mentioned Shutter which is in the repositories:
Which, yet again, begs the question "Why?"

Unless you give some kind of justification - some kind of reason for wanting something other than 'scrot' (which is installed by default), nobody's going to go chasing a URL.

Seeing this Post started 6 years ago, thought an alternative may be of interest, and Shutter is just an apt away:

https://packages.debian.org/stretch/shutter
Adieu

User avatar
scruss
Posts: 1674
Joined: Sat Jun 09, 2012 12:25 pm
Location: Toronto, ON
Contact: Website

Re: Screenshot?

Sun Feb 25, 2018 3:46 am

n67 wrote:
Sat Feb 24, 2018 9:51 am
Seems to do about the same as scrot or, for that matter, display from ImageMagick.
raspi2png doesn't need X, unlike scrot or ImageMagick. If it's displaying to the framebuffer, raspi2png will grab it. Raw SDL like RetroPie? Works great. scrot and IM would give up on this.

Since I mentioned scrot before in this thread, credit me with enough intelligence to add something … Also, that's not what “begs the question” means.
‘Remember the Golden Rule of Selling: “Do not resort to violence.”’ — McGlashan.

Return to “Raspbian”

Who is online

Users browsing this forum: No registered users and 21 guests