For Programmers: Free Programming Magazines  


Home > Archive > Unix Programming > April 2005 > Screen Capture Using C









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Screen Capture Using C
alr288@psu.edu

2005-04-12, 3:58 am

Hello Everyone,
This may be sort of a newbie question and I realize that it is
probably frontend specifc. Assuming that there is a desktop
environment I would like to be able to grab a screen scrap using a C
program. The code that works for OS X is as follows:

PixMap pixMap;
GetQDGlobalsScreenBits((BitMap*)&pixMap);

if anyone knows the answer to this questions or where I could find unix
based c documentation I would greatly appreciate it.
Best, Andrew

Michel Bardiaux

2005-04-12, 8:57 am

alr288@psu.edu wrote:
> Hello Everyone,
> This may be sort of a newbie question and I realize that it is
> probably frontend specifc. Assuming that there is a desktop
> environment I would like to be able to grab a screen scrap using a C
> program. The code that works for OS X is as follows:
>
> PixMap pixMap;
> GetQDGlobalsScreenBits((BitMap*)&pixMap);
>
> if anyone knows the answer to this questions or where I could find unix
> based c documentation I would greatly appreciate it.
> Best, Andrew
>

Basically, XGetImage.

For details, look in the source code for xwd (part of the X11R6
distribution; http://www.x.org)

--
Michel Bardiaux
Peaktime Belgium S.A. Bd. du Souverain, 191 B-1160 Bruxelles
Tel : +32 2 790.29.41
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com