2 * Copyright 2008 Henri Verbeet for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
22 #include "wine/test.h"
24 static IDXGIDevice
*create_device(void)
26 IDXGIDevice
*dxgi_device
;
30 if (SUCCEEDED(D3D10CreateDevice(NULL
, D3D10_DRIVER_TYPE_HARDWARE
, NULL
, 0, D3D10_SDK_VERSION
, &device
)))
32 if (SUCCEEDED(D3D10CreateDevice(NULL
, D3D10_DRIVER_TYPE_WARP
, NULL
, 0, D3D10_SDK_VERSION
, &device
)))
34 if (SUCCEEDED(D3D10CreateDevice(NULL
, D3D10_DRIVER_TYPE_REFERENCE
, NULL
, 0, D3D10_SDK_VERSION
, &device
)))
40 hr
= ID3D10Device_QueryInterface(device
, &IID_IDXGIDevice
, (void **)&dxgi_device
);
41 ok(SUCCEEDED(hr
), "Created device does not implement IDXGIDevice\n");
42 ID3D10Device_Release(device
);
47 static void test_device_interfaces(void)
54 if (!(device
= create_device()))
56 skip("Failed to create device, skipping tests.\n");
60 if (SUCCEEDED(hr
= IDXGIDevice_QueryInterface(device
, &IID_IUnknown
, (void **)&obj
)))
61 IUnknown_Release(obj
);
62 ok(SUCCEEDED(hr
), "IDXGIDevice does not implement IUnknown\n");
64 if (SUCCEEDED(hr
= IDXGIDevice_QueryInterface(device
, &IID_IDXGIObject
, (void **)&obj
)))
65 IUnknown_Release(obj
);
66 ok(SUCCEEDED(hr
), "IDXGIDevice does not implement IDXGIObject\n");
68 if (SUCCEEDED(hr
= IDXGIDevice_QueryInterface(device
, &IID_IDXGIDevice
, (void **)&obj
)))
69 IUnknown_Release(obj
);
70 ok(SUCCEEDED(hr
), "IDXGIDevice does not implement IDXGIDevice\n");
72 if (SUCCEEDED(hr
= IDXGIDevice_QueryInterface(device
, &IID_ID3D10Device
, (void **)&obj
)))
73 IUnknown_Release(obj
);
74 ok(SUCCEEDED(hr
), "IDXGIDevice does not implement ID3D10Device\n");
76 refcount
= IDXGIDevice_Release(device
);
77 ok(!refcount
, "Device has %u references left.\n", refcount
);
80 static void test_adapter_desc(void)
82 DXGI_ADAPTER_DESC1 desc1
;
83 IDXGIAdapter1
*adapter1
;
84 DXGI_ADAPTER_DESC desc
;
85 IDXGIAdapter
*adapter
;
90 if (!(device
= create_device()))
92 skip("Failed to create device, skipping tests.\n");
96 hr
= IDXGIDevice_GetAdapter(device
, &adapter
);
97 ok(SUCCEEDED(hr
), "GetAdapter failed, hr %#x.\n", hr
);
99 hr
= IDXGIAdapter_GetDesc(adapter
, NULL
);
100 ok(hr
== E_INVALIDARG
, "GetDesc returned %#x, expected %#x.\n",
103 hr
= IDXGIAdapter_GetDesc(adapter
, &desc
);
104 ok(SUCCEEDED(hr
), "GetDesc failed, hr %#x.\n", hr
);
106 trace("%s.\n", wine_dbgstr_w(desc
.Description
));
107 trace("%04x: %04x:%04x (rev %02x).\n",
108 desc
.SubSysId
, desc
.VendorId
, desc
.DeviceId
, desc
.Revision
);
109 trace("Dedicated video memory: %lu (%lu MB).\n",
110 desc
.DedicatedVideoMemory
, desc
.DedicatedVideoMemory
/ (1024 * 1024));
111 trace("Dedicated system memory: %lu (%lu MB).\n",
112 desc
.DedicatedSystemMemory
, desc
.DedicatedSystemMemory
/ (1024 * 1024));
113 trace("Shared system memory: %lu (%lu MB).\n",
114 desc
.SharedSystemMemory
, desc
.SharedSystemMemory
/ (1024 * 1024));
115 trace("LUID: %08x:%08x.\n", desc
.AdapterLuid
.HighPart
, desc
.AdapterLuid
.LowPart
);
117 hr
= IDXGIAdapter_QueryInterface(adapter
, &IID_IDXGIAdapter1
, (void **)&adapter1
);
118 ok(SUCCEEDED(hr
) || broken(hr
== E_NOINTERFACE
), "Got unexpected hr %#x.\n", hr
);
119 if (hr
== E_NOINTERFACE
)
122 hr
= IDXGIAdapter1_GetDesc1(adapter1
, &desc1
);
123 ok(SUCCEEDED(hr
), "GetDesc1 failed, hr %#x.\n", hr
);
125 ok(!lstrcmpW(desc
.Description
, desc1
.Description
),
126 "Got unexpected description %s.\n", wine_dbgstr_w(desc1
.Description
));
127 ok(desc1
.VendorId
== desc
.VendorId
, "Got unexpected vendor ID %04x.\n", desc1
.VendorId
);
128 ok(desc1
.DeviceId
== desc
.DeviceId
, "Got unexpected device ID %04x.\n", desc1
.DeviceId
);
129 ok(desc1
.SubSysId
== desc
.SubSysId
, "Got unexpected sub system ID %04x.\n", desc1
.SubSysId
);
130 ok(desc1
.Revision
== desc
.Revision
, "Got unexpected revision %02x.\n", desc1
.Revision
);
131 ok(desc1
.DedicatedVideoMemory
== desc
.DedicatedVideoMemory
,
132 "Got unexpected dedicated video memory %lu.\n", desc1
.DedicatedVideoMemory
);
133 ok(desc1
.DedicatedSystemMemory
== desc
.DedicatedSystemMemory
,
134 "Got unexpected dedicated system memory %lu.\n", desc1
.DedicatedSystemMemory
);
135 ok(desc1
.SharedSystemMemory
== desc
.SharedSystemMemory
,
136 "Got unexpected shared system memory %lu.\n", desc1
.SharedSystemMemory
);
137 ok(!memcmp(&desc
.AdapterLuid
, &desc1
.AdapterLuid
, sizeof(desc
.AdapterLuid
)),
138 "Got unexpected adapter LUID %08x:%08x.\n", desc1
.AdapterLuid
.HighPart
, desc1
.AdapterLuid
.LowPart
);
139 trace("Flags: %08x.\n", desc1
.Flags
);
141 IDXGIAdapter1_Release(adapter1
);
144 IDXGIAdapter_Release(adapter
);
145 refcount
= IDXGIDevice_Release(device
);
146 ok(!refcount
, "Device has %u references left.\n", refcount
);
149 static void test_create_surface(void)
151 ID3D10Texture2D
*texture
;
152 IDXGISurface
*surface
;
153 DXGI_SURFACE_DESC desc
;
158 if (!(device
= create_device()))
160 skip("Failed to create device, skipping tests.\n");
166 desc
.Format
= DXGI_FORMAT_R8G8B8A8_UNORM
;
167 desc
.SampleDesc
.Count
= 1;
168 desc
.SampleDesc
.Quality
= 0;
170 hr
= IDXGIDevice_CreateSurface(device
, &desc
, 1, DXGI_USAGE_RENDER_TARGET_OUTPUT
, NULL
, &surface
);
171 ok(SUCCEEDED(hr
), "Failed to create a dxgi surface, hr %#x\n", hr
);
173 hr
= IDXGISurface_QueryInterface(surface
, &IID_ID3D10Texture2D
, (void **)&texture
);
174 ok(SUCCEEDED(hr
), "Surface should implement ID3D10Texture2D\n");
175 if (SUCCEEDED(hr
)) ID3D10Texture2D_Release(texture
);
177 IDXGISurface_Release(surface
);
178 refcount
= IDXGIDevice_Release(device
);
179 ok(!refcount
, "Device has %u references left.\n", refcount
);
182 static void test_parents(void)
184 DXGI_SURFACE_DESC surface_desc
;
185 IDXGISurface
*surface
;
186 IDXGIFactory
*factory
;
187 IDXGIAdapter
*adapter
;
194 if (!(device
= create_device()))
196 skip("Failed to create device, skipping tests.\n");
200 surface_desc
.Width
= 512;
201 surface_desc
.Height
= 512;
202 surface_desc
.Format
= DXGI_FORMAT_R8G8B8A8_UNORM
;
203 surface_desc
.SampleDesc
.Count
= 1;
204 surface_desc
.SampleDesc
.Quality
= 0;
206 hr
= IDXGIDevice_CreateSurface(device
, &surface_desc
, 1, DXGI_USAGE_RENDER_TARGET_OUTPUT
, NULL
, &surface
);
207 ok(SUCCEEDED(hr
), "Failed to create a dxgi surface, hr %#x\n", hr
);
209 hr
= IDXGISurface_GetParent(surface
, &IID_IDXGIDevice
, (void **)&parent
);
210 IDXGISurface_Release(surface
);
211 ok(SUCCEEDED(hr
), "GetParent failed, hr %#x.\n", hr
);
212 ok(parent
== (IUnknown
*)device
, "Got parent %p, expected %p.\n", parent
, device
);
213 IUnknown_Release(parent
);
215 hr
= IDXGIDevice_GetAdapter(device
, &adapter
);
216 ok(SUCCEEDED(hr
), "GetAdapter failed, hr %#x.\n", hr
);
218 hr
= IDXGIAdapter_EnumOutputs(adapter
, 0, &output
);
219 if (hr
== DXGI_ERROR_NOT_FOUND
)
221 skip("Adapter has not outputs, skipping output tests.\n");
225 ok(SUCCEEDED(hr
), "EnumOutputs failed, hr %#x.\n", hr
);
227 hr
= IDXGIOutput_GetParent(output
, &IID_IDXGIAdapter
, (void **)&parent
);
228 IDXGIOutput_Release(output
);
229 ok(SUCCEEDED(hr
), "GetParent failed, hr %#x.\n", hr
);
230 ok(parent
== (IUnknown
*)adapter
, "Got parent %p, expected %p.\n", parent
, adapter
);
231 IUnknown_Release(parent
);
234 hr
= IDXGIAdapter_GetParent(adapter
, &IID_IDXGIFactory
, (void **)&factory
);
235 ok(SUCCEEDED(hr
), "GetParent failed, hr %#x.\n", hr
);
237 hr
= IDXGIFactory_GetParent(factory
, &IID_IUnknown
, (void **)&parent
);
238 ok(hr
== E_NOINTERFACE
, "GetParent returned %#x, expected %#x.\n", hr
, E_NOINTERFACE
);
239 ok(parent
== NULL
, "Got parent %p, expected %p.\n", parent
, NULL
);
240 IDXGIFactory_Release(factory
);
242 hr
= IDXGIDevice_GetParent(device
, &IID_IDXGIAdapter
, (void **)&parent
);
243 ok(SUCCEEDED(hr
), "GetParent failed, hr %#x.\n", hr
);
244 ok(parent
== (IUnknown
*)adapter
, "Got parent %p, expected %p.\n", parent
, adapter
);
245 IUnknown_Release(parent
);
247 IDXGIAdapter_Release(adapter
);
248 refcount
= IDXGIDevice_Release(device
);
249 ok(!refcount
, "Device has %u references left.\n", refcount
);
252 static void test_output(void)
254 IDXGIAdapter
*adapter
;
259 UINT mode_count
, mode_count_comp
, i
;
260 DXGI_MODE_DESC
*modes
;
262 if (!(device
= create_device()))
264 skip("Failed to create device, skipping tests.\n");
268 hr
= IDXGIDevice_GetAdapter(device
, &adapter
);
269 ok(SUCCEEDED(hr
), "GetAdapter failed, hr %#x.\n", hr
);
271 hr
= IDXGIAdapter_EnumOutputs(adapter
, 0, &output
);
272 if (hr
== DXGI_ERROR_NOT_FOUND
)
274 skip("Adapter doesn't have any outputs, skipping tests.\n");
275 IDXGIAdapter_Release(adapter
);
276 IDXGIDevice_Release(device
);
279 ok(SUCCEEDED(hr
), "EnumOutputs failed, hr %#x.\n", hr
);
281 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
, 0, NULL
, NULL
);
282 todo_wine
ok(hr
== DXGI_ERROR_INVALID_CALL
, "Got unexpected hr %#x.\n", hr
);
284 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
, 0, &mode_count
, NULL
);
286 || broken(hr
== DXGI_ERROR_NOT_CURRENTLY_AVAILABLE
), /* Remote Desktop Services / Win 7 testbot */
287 "Failed to list modes, hr %#x.\n", hr
);
288 if (hr
== DXGI_ERROR_NOT_CURRENTLY_AVAILABLE
)
290 skip("GetDisplayModeList() not supported, skipping tests.\n");
291 IDXGIOutput_Release(output
);
292 IDXGIAdapter_Release(adapter
);
293 IDXGIDevice_Release(device
);
296 mode_count_comp
= mode_count
;
298 hr
= IDXGIOutput_GetDisplayModeList(output
, 0, 0, &mode_count
, NULL
);
299 ok(SUCCEEDED(hr
), "Failed to list modes, hr %#x.\n", hr
);
300 ok(!mode_count
, "Got unexpected mode_count %u.\n", mode_count
);
302 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
303 DXGI_ENUM_MODES_SCALING
, &mode_count
, NULL
);
304 ok(SUCCEEDED(hr
), "Failed to list modes, hr %#x.\n", hr
);
305 ok(mode_count
>= mode_count_comp
, "Got unexpected mode_count %u, expected >= %u.\n", mode_count
, mode_count_comp
);
306 mode_count_comp
= mode_count
;
308 modes
= HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY
, sizeof(*modes
) * (mode_count
+ 10));
310 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
311 DXGI_ENUM_MODES_SCALING
, NULL
, modes
);
312 todo_wine
ok(hr
== DXGI_ERROR_INVALID_CALL
, "Got unexpected hr %#x.\n", hr
);
313 ok(!modes
[0].Height
, "No output was expected.\n");
316 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
317 DXGI_ENUM_MODES_SCALING
, &mode_count
, modes
);
318 todo_wine
ok(hr
== DXGI_ERROR_MORE_DATA
, "Got unexpected hr %#x.\n", hr
);
319 ok(!modes
[0].Height
, "No output was expected.\n");
321 mode_count
= mode_count_comp
;
322 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
323 DXGI_ENUM_MODES_SCALING
, &mode_count
, modes
);
324 ok(SUCCEEDED(hr
), "Failed to list modes, hr %#x.\n", hr
);
325 ok(mode_count
== mode_count_comp
, "Got unexpected mode_count %u, expected %u.\n", mode_count
, mode_count_comp
);
327 for (i
= 0; i
< mode_count
; i
++)
329 ok(modes
[i
].Height
&& modes
[i
].Width
, "Proper mode was expected\n");
333 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
334 DXGI_ENUM_MODES_SCALING
, &mode_count
, modes
);
335 ok(SUCCEEDED(hr
), "Failed to list modes, hr %#x.\n", hr
);
336 ok(mode_count
== mode_count_comp
, "Got unexpected mode_count %u, expected %u.\n", mode_count
, mode_count_comp
);
340 mode_count
= mode_count_comp
- 1;
341 hr
= IDXGIOutput_GetDisplayModeList(output
, DXGI_FORMAT_R8G8B8A8_UNORM
,
342 DXGI_ENUM_MODES_SCALING
, &mode_count
, modes
);
343 todo_wine
ok(hr
== DXGI_ERROR_MORE_DATA
, "Got unexpected hr %#x.\n", hr
);
344 ok(mode_count
== mode_count_comp
- 1, "Got unexpected mode_count %u, expected %u.\n",
345 mode_count
, mode_count_comp
- 1);
349 skip("Not enough modes for test, skipping.\n");
352 HeapFree(GetProcessHeap(), 0, modes
);
353 IDXGIOutput_Release(output
);
354 IDXGIAdapter_Release(adapter
);
355 refcount
= IDXGIDevice_Release(device
);
356 ok(!refcount
, "Device has %u references left.\n", refcount
);
363 BOOL numerator_should_pass
;
364 BOOL denominator_should_pass
;
367 static void test_createswapchain(void)
370 IDXGIAdapter
*adapter
;
371 IDXGIFactory
*factory
;
374 IDXGISwapChain
*swapchain
;
375 DXGI_SWAP_CHAIN_DESC creation_desc
, result_desc
;
380 const struct refresh_rates refresh_list
[] =
382 {60, 60, FALSE
, FALSE
},
383 {60, 0, TRUE
, FALSE
},
385 { 0, 60, TRUE
, FALSE
},
386 { 0, 0, TRUE
, FALSE
},
389 if (!(device
= create_device()))
391 skip("Failed to create device, skipping tests.\n");
395 wc
.lpfnWndProc
= DefWindowProcA
;
396 wc
.lpszClassName
= "dxgi_test_wc";
400 creation_desc
.OutputWindow
= 0;
401 creation_desc
.BufferDesc
.Width
= 800;
402 creation_desc
.BufferDesc
.Height
= 600;
403 creation_desc
.BufferDesc
.RefreshRate
.Numerator
= 60;
404 creation_desc
.BufferDesc
.RefreshRate
.Denominator
= 60;
405 creation_desc
.BufferDesc
.Format
= DXGI_FORMAT_R8G8B8A8_UNORM
;
406 creation_desc
.BufferDesc
.ScanlineOrdering
= DXGI_MODE_SCANLINE_ORDER_UNSPECIFIED
;
407 creation_desc
.BufferDesc
.Scaling
= DXGI_MODE_SCALING_UNSPECIFIED
;
408 creation_desc
.SampleDesc
.Count
= 1;
409 creation_desc
.SampleDesc
.Quality
= 0;
410 creation_desc
.BufferUsage
= DXGI_USAGE_RENDER_TARGET_OUTPUT
;
411 creation_desc
.BufferCount
= 1;
412 creation_desc
.OutputWindow
= CreateWindowA("dxgi_test_wc", "dxgi_test", 0, 0, 0, 0, 0, 0, 0, 0, 0);
413 creation_desc
.Windowed
= TRUE
;
414 creation_desc
.SwapEffect
= DXGI_SWAP_EFFECT_DISCARD
;
415 creation_desc
.Flags
= 0;
417 hr
= IDXGIDevice_QueryInterface(device
, &IID_IUnknown
, (void **)&obj
);
418 ok(SUCCEEDED(hr
), "IDXGIDevice does not implement IUnknown\n");
420 hr
= IDXGIDevice_GetAdapter(device
, &adapter
);
421 ok(SUCCEEDED(hr
), "GetAdapter failed, hr %#x.\n", hr
);
423 hr
= IDXGIAdapter_GetParent(adapter
, &IID_IDXGIFactory
, (void **)&factory
);
424 ok(SUCCEEDED(hr
), "GetParent failed, hr %#x.\n", hr
);
426 hr
= IDXGIFactory_CreateSwapChain(factory
, obj
, &creation_desc
, &swapchain
);
427 ok(SUCCEEDED(hr
), "CreateSwapChain failed, hr %#x.\n", hr
);
429 hr
= IDXGISwapChain_GetDesc(swapchain
, NULL
);
430 ok(hr
== E_INVALIDARG
, "GetDesc unexpectedly returned %#x.\n", hr
);
432 IDXGISwapChain_Release(swapchain
);
434 for (i
= 0; i
< sizeof(refresh_list
)/sizeof(refresh_list
[0]); i
++)
436 creation_desc
.BufferDesc
.RefreshRate
.Numerator
= refresh_list
[i
].numerator
;
437 creation_desc
.BufferDesc
.RefreshRate
.Denominator
= refresh_list
[i
].denominator
;
439 hr
= IDXGIFactory_CreateSwapChain(factory
, obj
, &creation_desc
, &swapchain
);
440 ok(SUCCEEDED(hr
), "CreateSwapChain failed, hr %#x.\n", hr
);
442 hr
= IDXGISwapChain_GetDesc(swapchain
, &result_desc
);
443 ok(SUCCEEDED(hr
), "GetDesc failed, hr %#x.\n", hr
);
445 if (refresh_list
[i
].numerator_should_pass
)
446 ok(result_desc
.BufferDesc
.RefreshRate
.Numerator
== refresh_list
[i
].numerator
,
447 "Numerator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Numerator
);
449 todo_wine
ok(result_desc
.BufferDesc
.RefreshRate
.Numerator
== refresh_list
[i
].numerator
,
450 "Numerator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Numerator
);
452 if (refresh_list
[i
].denominator_should_pass
)
453 ok(result_desc
.BufferDesc
.RefreshRate
.Denominator
== refresh_list
[i
].denominator
,
454 "Denominator %u is %u.\n", i
,result_desc
.BufferDesc
.RefreshRate
.Denominator
);
456 todo_wine
ok(result_desc
.BufferDesc
.RefreshRate
.Denominator
== refresh_list
[i
].denominator
,
457 "Denominator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Denominator
);
459 IDXGISwapChain_Release(swapchain
);
462 creation_desc
.Windowed
= FALSE
;
464 for (i
= 0; i
< sizeof(refresh_list
)/sizeof(refresh_list
[0]); i
++)
466 creation_desc
.BufferDesc
.RefreshRate
.Numerator
= refresh_list
[i
].numerator
;
467 creation_desc
.BufferDesc
.RefreshRate
.Denominator
= refresh_list
[i
].denominator
;
469 hr
= IDXGIFactory_CreateSwapChain(factory
, obj
, &creation_desc
, &swapchain
);
470 ok(SUCCEEDED(hr
), "CreateSwapChain failed, hr %#x.\n", hr
);
472 hr
= IDXGISwapChain_GetDesc(swapchain
, &result_desc
);
473 ok(SUCCEEDED(hr
), "GetDesc failed, hr %#x.\n", hr
);
475 if (refresh_list
[i
].numerator_should_pass
)
476 ok(result_desc
.BufferDesc
.RefreshRate
.Numerator
== refresh_list
[i
].numerator
,
477 "Numerator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Numerator
);
479 todo_wine
ok(result_desc
.BufferDesc
.RefreshRate
.Numerator
== refresh_list
[i
].numerator
,
480 "Numerator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Numerator
);
482 if (refresh_list
[i
].denominator_should_pass
)
483 ok(result_desc
.BufferDesc
.RefreshRate
.Denominator
== refresh_list
[i
].denominator
,
484 "Denominator %u is %u.\n", i
,result_desc
.BufferDesc
.RefreshRate
.Denominator
);
486 todo_wine
ok(result_desc
.BufferDesc
.RefreshRate
.Denominator
== refresh_list
[i
].denominator
,
487 "Denominator %u is %u.\n", i
, result_desc
.BufferDesc
.RefreshRate
.Denominator
);
489 hr
= IDXGISwapChain_SetFullscreenState(swapchain
, FALSE
, NULL
);
490 todo_wine
ok(SUCCEEDED(hr
), "SetFullscreenState failed, hr %#x.\n", hr
);
492 IDXGISwapChain_Release(swapchain
);
495 IDXGIFactory_Release(factory
);
496 IDXGIAdapter_Release(adapter
);
497 IUnknown_Release(obj
);
498 refcount
= IDXGIDevice_Release(device
);
499 ok(!refcount
, "Device has %u references left.\n", refcount
);
505 test_device_interfaces();
506 test_create_surface();
509 test_createswapchain();