wined3d: Invalidate number of viewports set for the context.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2018-04-27 13:57:26 +03:00 committed by Alexandre Julliard
parent 5153ee48ed
commit b2061c8589
1 changed files with 2 additions and 0 deletions

View File

@ -2788,6 +2788,7 @@ void context_apply_blit_state(struct wined3d_context *context, const struct wine
if (context->blit_w != rt_size.cx || context->blit_h != rt_size.cy)
{
gl_info->gl_ops.gl.p_glViewport(0, 0, rt_size.cx, rt_size.cy);
context->viewport_count = WINED3D_MAX_VIEWPORTS;
context->blit_w = rt_size.cx;
context->blit_h = rt_size.cy;
/* No need to dirtify here, the states are still dirtified because
@ -2856,6 +2857,7 @@ void context_apply_blit_state(struct wined3d_context *context, const struct wine
if (gl_info->supported[ARB_CLIP_CONTROL])
GL_EXTCALL(glClipControl(GL_LOWER_LEFT, GL_NEGATIVE_ONE_TO_ONE));
gl_info->gl_ops.gl.p_glViewport(0, 0, rt_size.cx, rt_size.cy);
context->viewport_count = WINED3D_MAX_VIEWPORTS;
context_invalidate_state(context, STATE_VIEWPORT);
device->shader_backend->shader_disable(device->shader_priv, context);