mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d: Implement support for D3D12_FEATURE_D3D12_OPTIONS2.
Signed-off-by: Conor McCarthy <conor.mccarthy.444@gmail.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
committed by
Alexandre Julliard
parent
fad3b12703
commit
6e0590adf6
@@ -184,6 +184,13 @@ typedef enum D3D12_WRITEBUFFERIMMEDIATE_MODE
|
|||||||
D3D12_WRITEBUFFERIMMEDIATE_MODE_MARKER_OUT = 0x2,
|
D3D12_WRITEBUFFERIMMEDIATE_MODE_MARKER_OUT = 0x2,
|
||||||
} D3D12_WRITEBUFFERIMMEDIATE_MODE;
|
} D3D12_WRITEBUFFERIMMEDIATE_MODE;
|
||||||
|
|
||||||
|
typedef enum D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER
|
||||||
|
{
|
||||||
|
D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER_NOT_SUPPORTED = 0x0,
|
||||||
|
D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER_1 = 0x1,
|
||||||
|
D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER_2 = 0x2,
|
||||||
|
} D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER;
|
||||||
|
|
||||||
interface ID3D12Fence;
|
interface ID3D12Fence;
|
||||||
interface ID3D12RootSignature;
|
interface ID3D12RootSignature;
|
||||||
interface ID3D12Heap;
|
interface ID3D12Heap;
|
||||||
@@ -1634,6 +1641,12 @@ typedef struct D3D12_FEATURE_DATA_ARCHITECTURE1
|
|||||||
BOOL IsolatedMMU;
|
BOOL IsolatedMMU;
|
||||||
} D3D12_FEATURE_DATA_ARCHITECTURE1;
|
} D3D12_FEATURE_DATA_ARCHITECTURE1;
|
||||||
|
|
||||||
|
typedef struct D3D12_FEATURE_DATA_D3D12_OPTIONS2
|
||||||
|
{
|
||||||
|
BOOL DepthBoundsTestSupported;
|
||||||
|
D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER ProgrammableSamplePositionsTier;
|
||||||
|
} D3D12_FEATURE_DATA_D3D12_OPTIONS2;
|
||||||
|
|
||||||
typedef enum D3D12_FEATURE
|
typedef enum D3D12_FEATURE
|
||||||
{
|
{
|
||||||
D3D12_FEATURE_D3D12_OPTIONS = 0,
|
D3D12_FEATURE_D3D12_OPTIONS = 0,
|
||||||
|
|||||||
@@ -1344,6 +1344,12 @@ static HRESULT vkd3d_init_device_caps(struct d3d12_device *device,
|
|||||||
device->feature_options1.ExpandedComputeResourceStates = TRUE;
|
device->feature_options1.ExpandedComputeResourceStates = TRUE;
|
||||||
device->feature_options1.Int64ShaderOps = features->shaderInt64;
|
device->feature_options1.Int64ShaderOps = features->shaderInt64;
|
||||||
|
|
||||||
|
/* Depth bounds test is enabled in D3D12_DEPTH_STENCIL_DESC1, which is not
|
||||||
|
* supported. */
|
||||||
|
device->feature_options2.DepthBoundsTestSupported = FALSE;
|
||||||
|
/* d3d12_command_list_SetSamplePositions() is not implemented. */
|
||||||
|
device->feature_options2.ProgrammableSamplePositionsTier = D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER_NOT_SUPPORTED;
|
||||||
|
|
||||||
if ((vr = VK_CALL(vkEnumerateDeviceExtensionProperties(physical_device, NULL, &count, NULL))) < 0)
|
if ((vr = VK_CALL(vkEnumerateDeviceExtensionProperties(physical_device, NULL, &count, NULL))) < 0)
|
||||||
{
|
{
|
||||||
ERR("Failed to enumerate device extensions, vr %d.\n", vr);
|
ERR("Failed to enumerate device extensions, vr %d.\n", vr);
|
||||||
@@ -2745,6 +2751,23 @@ static HRESULT STDMETHODCALLTYPE d3d12_device_CheckFeatureSupport(ID3D12Device *
|
|||||||
return S_OK;
|
return S_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case D3D12_FEATURE_D3D12_OPTIONS2:
|
||||||
|
{
|
||||||
|
D3D12_FEATURE_DATA_D3D12_OPTIONS2 *data = feature_data;
|
||||||
|
|
||||||
|
if (feature_data_size != sizeof(*data))
|
||||||
|
{
|
||||||
|
WARN("Invalid size %u.\n", feature_data_size);
|
||||||
|
return E_INVALIDARG;
|
||||||
|
}
|
||||||
|
|
||||||
|
*data = device->feature_options2;
|
||||||
|
|
||||||
|
TRACE("Depth bounds test %#x.\n", data->DepthBoundsTestSupported);
|
||||||
|
TRACE("Programmable sample positions tier %#x.\n", data->ProgrammableSamplePositionsTier);
|
||||||
|
return S_OK;
|
||||||
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
FIXME("Unhandled feature %#x.\n", feature);
|
FIXME("Unhandled feature %#x.\n", feature);
|
||||||
return E_NOTIMPL;
|
return E_NOTIMPL;
|
||||||
|
|||||||
@@ -1132,6 +1132,7 @@ struct d3d12_device
|
|||||||
|
|
||||||
D3D12_FEATURE_DATA_D3D12_OPTIONS feature_options;
|
D3D12_FEATURE_DATA_D3D12_OPTIONS feature_options;
|
||||||
D3D12_FEATURE_DATA_D3D12_OPTIONS1 feature_options1;
|
D3D12_FEATURE_DATA_D3D12_OPTIONS1 feature_options1;
|
||||||
|
D3D12_FEATURE_DATA_D3D12_OPTIONS2 feature_options2;
|
||||||
|
|
||||||
struct vkd3d_vulkan_info vk_info;
|
struct vkd3d_vulkan_info vk_info;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user