libs/vkd3d-shader: Emit InvocationId for geometry and tessellation shaders.

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 2018-02-04 23:58:25 +01:00 committed by Alexandre Julliard
parent f7cace8216
commit 0ecbdbe823
2 changed files with 5 additions and 0 deletions

View File

@ -1557,7 +1557,9 @@ static bool shader_sm4_is_scalar_register(const struct vkd3d_shader_register *re
switch (reg->type)
{
case VKD3DSPR_DEPTHOUT:
case VKD3DSPR_GSINSTID:
case VKD3DSPR_LOCALTHREADINDEX:
case VKD3DSPR_OUTPOINTID:
case VKD3DSPR_PRIMID:
return true;
default:

View File

@ -2779,6 +2779,9 @@ vkd3d_spirv_builtin_table[] =
{VKD3D_SIV_NONE, VKD3DSPR_LOCALTHREADINDEX, VKD3D_TYPE_INT, 1, SpvBuiltInLocalInvocationIndex},
{VKD3D_SIV_NONE, VKD3DSPR_THREADGROUPID, VKD3D_TYPE_INT, 3, SpvBuiltInWorkgroupId},
{VKD3D_SIV_NONE, VKD3DSPR_GSINSTID, VKD3D_TYPE_INT, 1, SpvBuiltInInvocationId},
{VKD3D_SIV_NONE, VKD3DSPR_OUTPOINTID, VKD3D_TYPE_INT, 1, SpvBuiltInInvocationId},
{VKD3D_SIV_NONE, VKD3DSPR_DEPTHOUT, VKD3D_TYPE_FLOAT, 1, SpvBuiltInFragDepth},
{VKD3D_SIV_POSITION, ~0u, VKD3D_TYPE_FLOAT, 4, SpvBuiltInPosition},