MCI_CAPTURE

The MCI_CAPTURE command captures the contents of the frame buffer and stores it in a specified file. Digital-video devices recognize this command.

To send this command, call the mciSendCommand function with the following parameters.

MCIERROR mciSendCommand(
  MCIDEVICEID wDeviceID, 
  MCI_CAPTURE, 
  DWORD dwFlags, 
  (DWORD) (LPMCI_DGV_CAPTURE_PARMS) lpCapture
);

Parameters

wDeviceID

Device identifier of the MCI device that is to receive the command message.

dwFlags

MCI_NOTIFY, MCI_WAIT, or MCI_TEST. For information about these flags, see The Wait, Notify, and Test Flags.

lpCapture

Pointer to an MCI_DGV_CAPTURE_PARMS structure.

Return Values

Returns zero if successful or an error otherwise.

Remarks

The following additional flags apply to digital-video devices:

MCI_DGV_CAPTURE_AS

The lpstrFileName member of the structure identified by lpCapture contains an address of a buffer specifying the destination path and filename. (This flag is required.)

MCI_DGV_CAPTURE_AT

The rc member of the structure identified by lpCapture contains a valid rectangle. The rectangle specifies the rectangular region within the frame buffer that is cropped and saved to disk. If omitted, the cropped region defaults to the rectangle specified or defaulted on a previous MCI_PUT command that specifies the source area for this instance of the device driver.

Requirements

**  Windows NT/2000/XP:** Included in Windows NT 3.1 and later.
**  Windows 95/98/Me:** Included in Windows 95 and later.
**  Header:** Declared in Mmsystem.h; include Windows.h.

See Also

MCI, MCI Commands, MCI_DGV_CAPTURE_PARMS, MCI_PUT