The following code illustrates how to set the source and destination rectangle arrays for the transformation of the video.
MCI_DGV_RECT_PARMS mciRectParms;
USHORT usUserParm = 0;
ULONG ulReturn;
/* An example of changing the SOURCE area to a
sub-rectangle of the total input */
memset (&mciRectParms, 0x00, sizeof (MCI_DGV_RECT_PARMS));
mciRectParms.hwndCallback = hwndNotify;
mciRectParms.rc.xLeft = lX1;
mciRectParms.rc.yBottom = lY1;
mciRectParms.rc.xRight = lX2;
mciRectParms.rc.yTop = lY2;
ulReturn = mciSendCommand(usDeviceID, MCI_PUT,
MCI_WAIT | MCI_DGV_PUT_RECT |
MCI_DGV_RECORD | MCI_DGV_PUT_SOURCE,
(PVOID)&mciRectParms,
usUserParm);