vkd3d-shader/ir: Validate PATCHCONST destination parameters using a uniform helper.

This commit is contained in:
Giovanni Mascellani 2024-12-13 16:35:26 +01:00 committed by Henri Verbeet
parent 38a5c905db
commit b194e5dc4e
Notes: Henri Verbeet 2024-12-17 16:53:02 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1320

View File

@ -8076,9 +8076,7 @@ static void vsir_validate_dst_param(struct validation_context *ctx,
break;
case VKD3DSPR_PATCHCONST:
if (ctx->program->shader_version.type != VKD3D_SHADER_TYPE_HULL)
validator_error(ctx, VKD3D_SHADER_ERROR_VSIR_INVALID_REGISTER_TYPE,
"PATCHCONST register used as destination parameters are only allowed in Hull Shaders.");
vsir_validate_io_dst_param(ctx, dst);
break;
default: