From f3b76a72c781ab47db163162b4945fef0cd13fcb Mon Sep 17 00:00:00 2001 From: jp9000 Date: Sat, 8 Aug 2015 00:55:46 -0700 Subject: [PATCH] UI: Recalculate main preview scale on video reset Fixes a minor bug introduced by the windowless graphics context merge. When setting a new base resolution, it would not recalculate the preview size, and the preview would display the wrong size until the main window was resized by the user. This patch makes it so that it calls the recalculation function when the base resolution is changed to prevent that from happening. --- obs/window-basic-main.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/obs/window-basic-main.cpp b/obs/window-basic-main.cpp index b68003e22..bec8431e2 100644 --- a/obs/window-basic-main.cpp +++ b/obs/window-basic-main.cpp @@ -2043,6 +2043,8 @@ int OBSBasic::ResetVideo() ovi.graphics_module = DL_OPENGL; ret = AttemptToResetVideo(&ovi); } + } else if (ret == OBS_VIDEO_SUCCESS) { + ResizePreview(ovi.base_width, ovi.base_height); } return ret;