How to capture screen

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.
Post Reply
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

How to capture screen

Post by foruforewer »

I had searched for this in forum, but could not found exact line of code. Can you please tell how to capture screen/active screen with command line just like "Princ Screen" button
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Re: How to capture screen

Post by foruforewer »

Please help me in this...
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: How to capture screen

Post by anthony »

Do you mean like the "Print" button? For X windows use...

Code: Select all

convert x:root image.png
See IM Examples... X Windows Input
http://www.imagemagick.org/Usage/files/#x


I myself use a shell script to save the the current window into a file, then jiggle to the window to say 'I'm done'
It works well for me :-)
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
foruforewer
Posts: 26
Joined: 2011-02-08T04:37:21-07:00
Authentication code: 8675308

Re: How to capture screen

Post by foruforewer »

While running that command, it shows

Code: Select all

Magick: unable to open X server `': No such file or directory @ error/xwindow.c/XImportImage/4871.
Werty
Posts: 66
Joined: 2010-08-06T05:37:36-07:00
Authentication code: 8675308

Re: How to capture screen

Post by Werty »

x: is available for *nix only, if you are running windows then there is no such option, you'd have to go with one of the API's. (afaik, please correct if wrong)
Windows 7 user
Post Reply