Henri Verbeet : d3d9: Prefer bind flags over usage flags in d3d9_device_ColorFill().
Alexandre Julliard
julliard at winehq.org
Mon Nov 5 15:51:52 CST 2018
Module: wine
Branch: master
Commit: cc0c7d727b62f6d9ee2cfda60b5bbcc7279281ff
URL: https://source.winehq.org/git/wine.git/?a=commit;h=cc0c7d727b62f6d9ee2cfda60b5bbcc7279281ff
Author: Henri Verbeet <hverbeet at codeweavers.com>
Date: Mon Nov 5 15:31:56 2018 +0330
d3d9: Prefer bind flags over usage flags in d3d9_device_ColorFill().
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/d3d9/device.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/d3d9/device.c b/dlls/d3d9/device.c
index e513549..1e7c0ea 100644
--- a/dlls/d3d9/device.c
+++ b/dlls/d3d9/device.c
@@ -1750,13 +1750,13 @@ static HRESULT WINAPI d3d9_device_ColorFill(IDirect3DDevice9Ex *iface,
WARN("Colour fills are not allowed on surfaces with resource access %#x.\n", desc.access);
return D3DERR_INVALIDCALL;
}
- if ((desc.usage & (WINED3DUSAGE_RENDERTARGET | WINED3DUSAGE_TEXTURE)) == WINED3DUSAGE_TEXTURE)
+ if ((desc.bind_flags & (WINED3D_BIND_RENDER_TARGET | WINED3D_BIND_SHADER_RESOURCE)) == WINED3D_BIND_SHADER_RESOURCE)
{
wined3d_mutex_unlock();
WARN("Colorfill is not allowed on non-RT textures, returning D3DERR_INVALIDCALL.\n");
return D3DERR_INVALIDCALL;
}
- if (desc.usage & WINED3DUSAGE_DEPTHSTENCIL)
+ if (desc.bind_flags & WINED3D_BIND_DEPTH_STENCIL)
{
wined3d_mutex_unlock();
WARN("Colorfill is not allowed on depth stencil surfaces, returning D3DERR_INVALIDCALL.\n");
More information about the wine-cvs
mailing list