vkd3d: Require D3D12_ROOT_SIGNATURE_FLAG_ALLOW_STREAM_OUTPUT for stream output.

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:
Józef Kucia
2019-01-16 12:44:57 +01:00
committed by Alexandre Julliard
parent bb7d1046da
commit 15713840b4
3 changed files with 28 additions and 2 deletions

View File

@@ -2425,6 +2425,12 @@ static void test_create_graphics_pipeline_state(void)
unsigned int i;
HRESULT hr;
static const D3D12_SO_DECLARATION_ENTRY so_declaration[] =
{
{0, "SV_Position", 0, 0, 4, 0},
};
static const unsigned int strides[] = {16};
if (!(device = create_device()))
{
skip("Failed to create device.\n");
@@ -2537,6 +2543,16 @@ static void test_create_graphics_pipeline_state(void)
&IID_ID3D12PipelineState, (void **)&pipeline_state);
ok(hr == E_INVALIDARG, "Got unexpected hr %#x.\n", hr);
/* Stream output without D3D12_ROOT_SIGNATURE_FLAG_ALLOW_STREAM_OUTPUT. */
init_pipeline_state_desc(&pso_desc, root_signature, DXGI_FORMAT_R8G8B8A8_UNORM, NULL, NULL, NULL);
pso_desc.StreamOutput.NumEntries = ARRAY_SIZE(so_declaration);
pso_desc.StreamOutput.pSODeclaration = so_declaration;
pso_desc.StreamOutput.pBufferStrides = strides;
pso_desc.StreamOutput.NumStrides = ARRAY_SIZE(strides);
hr = ID3D12Device_CreateGraphicsPipelineState(device, &pso_desc,
&IID_ID3D12PipelineState, (void **)&pipeline_state);
ok(hr == E_INVALIDARG, "Got unexpected hr %#x.\n", hr);
refcount = ID3D12RootSignature_Release(root_signature);
ok(!refcount, "ID3D12RootSignature has %u references left.\n", (unsigned int)refcount);
refcount = ID3D12Device_Release(device);