CAPTURE *cap = create_capture();Use
BITMAP *bmp = capture_frame(cap);
capture_frame_nb
to capture a frame in nonblocking mode (a NULL pointer is returned if no frame is available). Should work on Mac OS X, Linux, Windows; only tested on Windows.(Source)