From fe1f06c856b768e9afcc9ba9ab8ef09b7152678c Mon Sep 17 00:00:00 2001 From: ameerj <52414509+ameerj@users.noreply.github.com> Date: Sat, 20 Nov 2021 17:48:22 -0500 Subject: Fix screenshot dimensions when at 1x scale This was regressed by ART. Prior to ART, the screenshots were saved at the title's framebuffer resolution. A misunderstanding of the existing logic led to screenshot dimensions becoming dependent on the host render window size. This changes the behavior to match how it was prior to ART at 1x, with screenshots now always being the title's framebuffer dimensions scaled by the resolution scaling factor. --- src/core/frontend/framebuffer_layout.h | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'src/core/frontend/framebuffer_layout.h') diff --git a/src/core/frontend/framebuffer_layout.h b/src/core/frontend/framebuffer_layout.h index 2e36c0163..8e341e4e2 100644 --- a/src/core/frontend/framebuffer_layout.h +++ b/src/core/frontend/framebuffer_layout.h @@ -35,17 +35,8 @@ enum class AspectRatio { struct FramebufferLayout { u32 width{ScreenUndocked::Width}; u32 height{ScreenUndocked::Height}; - bool is_srgb{}; - Common::Rectangle screen; - - /** - * Returns the ration of pixel size of the screen, compared to the native size of the undocked - * Switch screen. - */ - float GetScalingRatio() const { - return static_cast(screen.GetWidth()) / ScreenUndocked::Width; - } + bool is_srgb{}; }; /** -- cgit v1.2.3