Commit 2a8dae52 authored by Matteo Bruni's avatar Matteo Bruni Committed by Alexandre Julliard

d3dx9/tests: Fix expected values when mipmaps on cube maps are not supported.

parent 8ca7617d
......@@ -402,6 +402,7 @@ static void test_D3DXCheckCubeTextureRequirements(IDirect3DDevice9 *device)
size = 284;
mipmaps = 20;
expected = caps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP_POW2 ? 10 : 9;
expected = caps.TextureCaps & D3DPTEXTURECAPS_MIPCUBEMAP ? expected : 1;
hr = D3DXCheckCubeTextureRequirements(device, &size, &mipmaps, 0, NULL, D3DPOOL_DEFAULT);
ok(hr == D3D_OK, "D3DXCheckCubeTextureRequirements returned %#x, expected %#x\n", hr, D3D_OK);
ok(mipmaps == expected, "Returned mipmaps %d, expected %d\n", mipmaps, expected);
......@@ -409,6 +410,7 @@ static void test_D3DXCheckCubeTextureRequirements(IDirect3DDevice9 *device)
size = 63;
mipmaps = 9;
expected = caps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP_POW2 ? 7 : 6;
expected = caps.TextureCaps & D3DPTEXTURECAPS_MIPCUBEMAP ? expected : 1;
hr = D3DXCheckCubeTextureRequirements(device, &size, &mipmaps, 0, NULL, D3DPOOL_DEFAULT);
ok(hr == D3D_OK, "D3DXCheckCubeTextureRequirements returned %#x, expected %#x\n", hr, D3D_OK);
ok(mipmaps == expected, "Returned mipmaps %d, expected %d\n", mipmaps, expected);
......
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