From: Józef Kucia jkucia@codeweavers.com
Signed-off-by: Józef Kucia jkucia@codeweavers.com --- libs/vkd3d/state.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/libs/vkd3d/state.c b/libs/vkd3d/state.c index e9f73e82b44f..18addf39409d 100644 --- a/libs/vkd3d/state.c +++ b/libs/vkd3d/state.c @@ -904,7 +904,8 @@ static HRESULT d3d12_root_signature_init(struct d3d12_root_signature *root_signa root_signature->static_sampler_count = 0; root_signature->static_samplers = NULL;
- if (desc->Flags & ~D3D12_ROOT_SIGNATURE_FLAG_ALLOW_STREAM_OUTPUT) + if (desc->Flags & ~(D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT + | D3D12_ROOT_SIGNATURE_FLAG_ALLOW_STREAM_OUTPUT)) FIXME("Ignoring root signature flags %#x.\n", desc->Flags);
if (FAILED(hr = d3d12_root_signature_info_from_desc(&info, desc))) @@ -2282,6 +2283,14 @@ static HRESULT d3d12_pipeline_state_init_graphics(struct d3d12_pipeline_state *s graphics->attribute_count = ARRAY_SIZE(graphics->attributes); }
+ if (graphics->attribute_count + && !(root_signature->flags & D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT)) + { + WARN("Input layout is used without D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT.\n"); + hr = E_INVALIDARG; + goto fail; + } + if (FAILED(hr = compute_input_layout_offsets(&desc->InputLayout, aligned_offsets))) goto fail;