mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-01-28 13:05:02 -08:00
tests: Add test for D3D12_FEATURE_FORMAT_INFO.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
a2f38f88e2
commit
7829461d6d
@ -966,6 +966,7 @@ static void test_check_feature_support(void)
|
||||
D3D12_FEATURE_DATA_FEATURE_LEVELS feature_levels;
|
||||
D3D_FEATURE_LEVEL max_supported_feature_level;
|
||||
D3D12_FEATURE_DATA_ARCHITECTURE architecture;
|
||||
D3D12_FEATURE_DATA_FORMAT_INFO format_info;
|
||||
ID3D12Device *device;
|
||||
ULONG refcount;
|
||||
HRESULT hr;
|
||||
@ -1079,6 +1080,30 @@ static void test_check_feature_support(void)
|
||||
ok(feature_levels.MaxSupportedFeatureLevel == 0x3000,
|
||||
"Got unexpected max feature level %#x.\n", feature_levels.MaxSupportedFeatureLevel);
|
||||
|
||||
/* Format info. */
|
||||
memset(&format_info, 0, sizeof(format_info));
|
||||
hr = ID3D12Device_CheckFeatureSupport(device, D3D12_FEATURE_FORMAT_INFO,
|
||||
&format_info, sizeof(format_info));
|
||||
todo ok(hr == S_OK, "Failed to get format info, hr %#x.\n", hr);
|
||||
ok(format_info.Format == DXGI_FORMAT_UNKNOWN, "Got unexpected format %#x.\n", format_info.Format);
|
||||
todo ok(format_info.PlaneCount == 1, "Got unexpected plane count %u.\n", format_info.PlaneCount);
|
||||
|
||||
memset(&format_info, 0, sizeof(format_info));
|
||||
format_info.Format = DXGI_FORMAT_R8G8B8A8_UNORM;
|
||||
hr = ID3D12Device_CheckFeatureSupport(device, D3D12_FEATURE_FORMAT_INFO,
|
||||
&format_info, sizeof(format_info));
|
||||
todo ok(hr == S_OK, "Failed to get format info, hr %#x.\n", hr);
|
||||
ok(format_info.Format == DXGI_FORMAT_R8G8B8A8_UNORM, "Got unexpected format %#x.\n", format_info.Format);
|
||||
todo ok(format_info.PlaneCount == 1, "Got unexpected plane count %u.\n", format_info.PlaneCount);
|
||||
|
||||
memset(&format_info, 0, sizeof(format_info));
|
||||
format_info.Format = DXGI_FORMAT_R24G8_TYPELESS;
|
||||
hr = ID3D12Device_CheckFeatureSupport(device, D3D12_FEATURE_FORMAT_INFO,
|
||||
&format_info, sizeof(format_info));
|
||||
todo ok(hr == S_OK, "Failed to get format info, hr %#x.\n", hr);
|
||||
ok(format_info.Format == DXGI_FORMAT_R24G8_TYPELESS, "Got unexpected format %#x.\n", format_info.Format);
|
||||
todo ok(format_info.PlaneCount == 2, "Got unexpected plane count %u.\n", format_info.PlaneCount);
|
||||
|
||||
/* GPU virtual address */
|
||||
memset(&gpu_virtual_address, 0, sizeof(gpu_virtual_address));
|
||||
hr = ID3D12Device_CheckFeatureSupport(device, D3D12_FEATURE_GPU_VIRTUAL_ADDRESS_SUPPORT,
|
||||
|
Loading…
x
Reference in New Issue
Block a user