cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
print screen to .bmp
print screen to .bmp
Jan 23, 2015 at 12:04pm UTC
Nanyo
(88)
Hi does anyone know a WORKING example of code that makes screenshot and saves it to a .bmp file?
Thanks!
Last edited on
Jan 24, 2015 at 2:31pm UTC
Jan 23, 2015 at 2:51pm UTC
cnoeval
(643)
You don't provide enough info for anyone to help you. C++ has no concept of your video display so it's entirely system dependent and will require some external libraries.
You can start here though:
https://msdn.microsoft.com/en-us/library/dd183402(v=vs.85).aspx
BTW, in windows Alt-PrntScrn will store an image of the active window to you clipboard. Cnlt-Alt-PrntScrn will copy the whole display area.
Jan 24, 2015 at 2:37pm UTC
Nanyo
(88)
sorry I wasn't clear enough. I want to simulate pressing prtscr and to copy it to a .bmp file.
I am using Windows professional on computer Acer Travelmate 5740
Also I am using Visual Studio 2013 Ultimate, if that is important. If any other information is needed I will be happy to give it.
And I also need the code to be as compact as possible.
Thanks
Topic archived. No new replies allowed.