mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-29 06:28:29 +00:00
If the viewport changes the cliprect should be updated
The clip rectangle is defined to be viewport relative, so if the viewport changes we need to update it. Fixes https://github.com/libsdl-org/SDL/issues/9094
This commit is contained in:
@@ -2479,6 +2479,7 @@ static int D3D11_RunCommandQueue(SDL_Renderer *renderer, SDL_RenderCommand *cmd,
|
||||
if (SDL_memcmp(viewport, &cmd->data.viewport.rect, sizeof(cmd->data.viewport.rect)) != 0) {
|
||||
SDL_copyp(viewport, &cmd->data.viewport.rect);
|
||||
rendererData->viewportDirty = SDL_TRUE;
|
||||
rendererData->cliprectDirty = SDL_TRUE;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
Reference in New Issue
Block a user