d3d9: Deal with failing surface creation.

This commit is contained in:
Stefan Dösinger 2007-07-24 21:15:55 +02:00 committed by Alexandre Julliard
parent 181ae2eba0
commit 39a8f1b2a4
1 changed files with 5 additions and 2 deletions

View File

@ -150,8 +150,11 @@ static void test_surface_alignment(IDirect3DDevice9 *device_ptr)
hr = IDirect3DDevice9_CreateTexture(device_ptr, 64, 64, 0, 0, MAKEFOURCC('D', 'X', 'T', '1'+i),
D3DPOOL_MANAGED, &pTexture, NULL);
ok(SUCCEEDED(hr), "IDirect3DDevice9_CreateTexture: %s\n", DXGetErrorString9(hr));
if (FAILED(hr)) continue;
ok(SUCCEEDED(hr) || hr == D3DERR_INVALIDCALL, "IDirect3DDevice9_CreateTexture: %s\n", DXGetErrorString9(hr));
if (FAILED(hr)) {
skip("DXT%d surfaces are not supported\n", i + 1);
continue;
}
for (j = IDirect3DBaseTexture9_GetLevelCount(pTexture) - 1; j >= 0; j--)
{