Skip to content

Commit 8aa5b97

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.
1 parent 1f7aa16 commit 8aa5b97

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
@@ -2627,7 +2627,7 @@ static void UpdateLogicalPresentation(SDL_Renderer *renderer)
26272627
const float logical_h = view->logical_h;
26282628
int iwidth, iheight;
26292629

2630-
if (renderer->target) {
2630+
if (!is_main_view && renderer->target) {
26312631
iwidth = (int)renderer->target->w;
26322632
iheight = (int)renderer->target->h;
26332633
} else {

0 commit comments

Comments
 (0)