From 9a06fd000b8b597298ccb3ae76d7f480df81aad5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Tue, 24 Jul 2007 15:36:15 +0200 Subject: [PATCH] d3d8: Only test volume textures if they are supported. --- dlls/d3d8/tests/device.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/dlls/d3d8/tests/device.c b/dlls/d3d8/tests/device.c index e5c8997e1ed..b0d41379786 100644 --- a/dlls/d3d8/tests/device.c +++ b/dlls/d3d8/tests/device.c @@ -481,8 +481,16 @@ static void test_refcount(void) { skip("Cube textures not supported\n"); } - hr = IDirect3DDevice8_CreateVolumeTexture( pDevice, 32, 32, 2, 0, 0, D3DFMT_X8R8G8B8, D3DPOOL_DEFAULT, &pVolumeTexture ); - CHECK_CALL( hr, "CreateVolumeTexture", pDevice, ++refcount ); + if(caps.TextureCaps & D3DPTEXTURECAPS_VOLUMEMAP) + { + hr = IDirect3DDevice8_CreateVolumeTexture( pDevice, 32, 32, 2, 0, 0, D3DFMT_X8R8G8B8, D3DPOOL_DEFAULT, &pVolumeTexture ); + CHECK_CALL( hr, "CreateVolumeTexture", pDevice, ++refcount ); + } + else + { + skip("Volume textures not supported\n"); + } + if (pVolumeTexture) { tmp = get_refcount( (IUnknown *)pVolumeTexture );