Signed-off-by: Henri Verbeet hverbeet@codeweavers.com --- dlls/wined3d/context_vk.c | 2 ++ dlls/wined3d/wined3d_private.h | 10 ++++++++++ 2 files changed, 12 insertions(+)
diff --git a/dlls/wined3d/context_vk.c b/dlls/wined3d/context_vk.c index 0600cdfceca..8ab0f6366ca 100644 --- a/dlls/wined3d/context_vk.c +++ b/dlls/wined3d/context_vk.c @@ -1745,6 +1745,8 @@ static bool wined3d_context_vk_update_graphics_pipeline_key(struct wined3d_conte if (key->ia_desc.topology != vk_topology) { key->ia_desc.topology = vk_topology; + key->ia_desc.primitiveRestartEnable = !(d3d_info->wined3d_creation_flags & WINED3D_NO_PRIMITIVE_RESTART) + && !wined3d_primitive_type_is_list(state->primitive_type);
update = true; } diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h index 9f40a331322..3450633b618 100644 --- a/dlls/wined3d/wined3d_private.h +++ b/dlls/wined3d/wined3d_private.h @@ -5949,6 +5949,16 @@ static inline VkImageAspectFlags vk_aspect_mask_from_format(const struct wined3d return mask; }
+static inline bool wined3d_primitive_type_is_list(enum wined3d_primitive_type t) +{ + return t == WINED3D_PT_POINTLIST + || t == WINED3D_PT_LINELIST + || t == WINED3D_PT_TRIANGLELIST + || t == WINED3D_PT_LINELIST_ADJ + || t == WINED3D_PT_TRIANGLELIST_ADJ + || t == WINED3D_PT_PATCH; +} + /* The WNDCLASS-Name for the fake window which we use to retrieve the GL capabilities */ #define WINED3D_OPENGL_WINDOW_CLASS_NAME "WineD3D_OpenGL"