wined3d: UpdateTexture requires a sysmem source and default destination.

This commit is contained in:
Stefan Dösinger 2013-08-26 02:01:30 +02:00 committed by Alexandre Julliard
parent 6bc3cbf1c5
commit 9fbc90b8e3
1 changed files with 7 additions and 2 deletions

View File

@ -4131,9 +4131,14 @@ HRESULT CDECL wined3d_device_update_texture(struct wined3d_device *device,
return WINED3DERR_INVALIDCALL;
}
if (src_texture == dst_texture)
if (src_texture->resource.pool != WINED3D_POOL_SYSTEM_MEM)
{
WARN("Source and destination are the same object, returning WINED3DERR_INVALIDCALL.\n");
WARN("Source texture not in WINED3D_POOL_SYSTEM_MEM, returning WINED3DERR_INVALIDCALL.\n");
return WINED3DERR_INVALIDCALL;
}
if (dst_texture->resource.pool != WINED3D_POOL_DEFAULT)
{
WARN("Destination texture not in WINED3D_POOL_DEFAULT, returning WINED3DERR_INVALIDCALL.\n");
return WINED3DERR_INVALIDCALL;
}