Commit cfb07e71 authored by H. Verbeet's avatar H. Verbeet Committed by Alexandre Julliard

wined3d: Set SFLAG_INSYSMEM when WINED3DLOCK_DISCARD is passed to IWineD3DSurfaceImpl_LockRect.

parent 582ae3f3
......@@ -763,8 +763,14 @@ static HRESULT WINAPI IWineD3DSurfaceImpl_LockRect(IWineD3DSurface *iface, WINED
}
}
if((Flags & WINED3DLOCK_DISCARD) || (This->Flags & SFLAG_INSYSMEM)) {
TRACE("WINED3DLOCK_DISCARD flag passed, or local copy is up to date, not downloading data\n");
if (Flags & WINED3DLOCK_DISCARD) {
/* Set SFLAG_INSYSMEM, so we'll never try to download the data from the texture. */
TRACE("WINED3DLOCK_DISCARD flag passed, marking local copy as up to date\n");
This->Flags |= SFLAG_INSYSMEM;
}
if (This->Flags & SFLAG_INSYSMEM) {
TRACE("Local copy is up to date, not downloading data\n");
goto lock_end;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment