The following code illustrates how to freeze the motion of a video image.
MCI_VID_RECT_PARMS mciFreezeParms; USHORT usUserParm = 0; ULONG ulReturn; /* Freezing OUTSIDE a sub-rectangle of the window */ memset (&mciFreezeParms, 0x00, sizeof (MCI_VID_RECT_PARMS)); mciFreezeParms.hwndCallback = hwndNotify; mciFreezeParms.rc.xLeft = lX1; mciFreezeParms.rc.yBottom = lY1; mciFreezeParms.rc.xRight = lX2; mciFreezeParms.rc.yTop = lY2; ulReturn = mciSendCommand(usDeviceID, MCI_FREEZE, MCI_WAIT | MCI_OVLY_FREEZE_RECT_OUTSIDE | MCI_OVLY_FREEZE (PVOID)&mciFreezeParms, usUserParm);