Module: wine Branch: master Commit: ed3f5081a3a408b247a2afc42d73064fd843089e URL: http://source.winehq.org/git/wine.git/?a=commit;h=ed3f5081a3a408b247a2afc42d...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Thu May 5 20:56:06 2011 +0200
d3d9/tests: Check if formats are supported for render targets in pixelshader_blending_test().
---
dlls/d3d9/tests/visual.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/d3d9/tests/visual.c b/dlls/d3d9/tests/visual.c index baf8243..a655974 100644 --- a/dlls/d3d9/tests/visual.c +++ b/dlls/d3d9/tests/visual.c @@ -8893,9 +8893,12 @@ static void pixelshader_blending_test(IDirect3DDevice9 *device) for(fmt_index=0; test_formats[fmt_index].textureFormat != 0; fmt_index++) { D3DFORMAT fmt = test_formats[fmt_index].textureFormat; - if(IDirect3D9_CheckDeviceFormat(d3d, 0, D3DDEVTYPE_HAL, D3DFMT_X8R8G8B8, 0, D3DRTYPE_TEXTURE, fmt) != D3D_OK) { - skip("%s textures not supported\n", test_formats[fmt_index].fmtName); - continue; + + if (IDirect3D9_CheckDeviceFormat(d3d, 0, D3DDEVTYPE_HAL, D3DFMT_X8R8G8B8, + D3DUSAGE_RENDERTARGET, D3DRTYPE_TEXTURE, fmt) != D3D_OK) + { + skip("%s textures not supported as render targets.\n", test_formats[fmt_index].fmtName); + continue; }
hr = IDirect3DDevice9_Clear(device, 0, NULL, D3DCLEAR_TARGET, 0xffffffff, 0.0, 0);