HRESULT PageLock(DWORD dwFlags);
Prevents a system-memory surface from being paged out while a blit operation using direct memory access (DMA) transfers to or from system memory is in progress.
·Returns DD_OK if successful, or one of the following error values otherwise:
dwFlags
This parameter is currently not used and must be set to 0.
The performance of the operating system could be negatively affected if too much memory is locked.
A lock count is maintained for each surface and is incremented each time IDirectDrawSurface2::PageLock is called for that surface. The count is decremented when IDirectDrawSurface2::PageUnlock is called. When the count reaches 0, the memory is unlocked and can then be paged by the operating system.
This method works only on system-memory surfaces; it will not page lock a display-memory surface or an emulated primary surface. If an application calls this method on a display memory surface, the method will do nothing except return DD_OK.
This method was not implemented in the IDirectDraw interface.