Skip to content

Commit 8d60435

Browse files
Kontrabantslouken
authored andcommitted
renderer: Always use the output size when updating the main view
The main view always reflects the size of the output, so don't use the dimensions of the currently bound render target texture when updating it, or it will reflect an incorrect size when the render target texture is unbound. (cherry picked from commit 8aa5b97)
1 parent 8410e11 commit 8d60435

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/render/SDL_render.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2573,7 +2573,7 @@ static void UpdateLogicalPresentation(SDL_Renderer *renderer)
25732573
const float logical_h = view->logical_h;
25742574
int iwidth, iheight;
25752575

2576-
if (renderer->target) {
2576+
if (!is_main_view && renderer->target) {
25772577
iwidth = (int)renderer->target->w;
25782578
iheight = (int)renderer->target->h;
25792579
} else {

0 commit comments

Comments
 (0)