[PATCH vkd3d 03/12] vkd3d: Do not call vkCmdPushConstants() with a count of zero (KHRONOS_validation).
Giovanni Mascellani
gmascellani at codeweavers.com
Tue Apr 19 05:50:04 CDT 2022
Signed-off-by: Giovanni Mascellani <gmascellani at codeweavers.com>
Il 18/04/22 08:33, Giovanni Mascellani ha scritto:
> From: Zebediah Figura <zfigura at codeweavers.com>
>
> ---
> libs/vkd3d/command.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/libs/vkd3d/command.c b/libs/vkd3d/command.c
> index 09171fe4..481553d4 100644
> --- a/libs/vkd3d/command.c
> +++ b/libs/vkd3d/command.c
> @@ -4657,8 +4657,9 @@ static void d3d12_command_list_set_root_constants(struct d3d12_command_list *lis
> const struct d3d12_root_constant *c;
>
> c = root_signature_get_32bit_constants(root_signature, index);
> - VK_CALL(vkCmdPushConstants(list->vk_command_buffer, root_signature->vk_pipeline_layout,
> - c->stage_flags, c->offset + offset * sizeof(uint32_t), count * sizeof(uint32_t), data));
> + if (count)
> + VK_CALL(vkCmdPushConstants(list->vk_command_buffer, root_signature->vk_pipeline_layout,
> + c->stage_flags, c->offset + offset * sizeof(uint32_t), count * sizeof(uint32_t), data));
> }
>
> static void STDMETHODCALLTYPE d3d12_command_list_SetComputeRoot32BitConstant(ID3D12GraphicsCommandList2 *iface,
More information about the wine-devel
mailing list