From d73437c293c2f47cab48c46f844eb6ba0ad95528 Mon Sep 17 00:00:00 2001 From: rsn8887 Date: Sat, 2 Dec 2017 11:46:11 -0600 Subject: PSP2: fix odd resolutions on PSP2, fixes Phantasmagoria --- backends/graphics/psp2sdl/psp2sdl-graphics.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'backends') diff --git a/backends/graphics/psp2sdl/psp2sdl-graphics.cpp b/backends/graphics/psp2sdl/psp2sdl-graphics.cpp index affcf9d8f5..f7d6bcb44b 100644 --- a/backends/graphics/psp2sdl/psp2sdl-graphics.cpp +++ b/backends/graphics/psp2sdl/psp2sdl-graphics.cpp @@ -459,6 +459,10 @@ void PSP2SdlGraphicsManager::setAspectRatioCorrection(bool enable) { } SDL_Surface *PSP2SdlGraphicsManager::SDL_SetVideoMode(int width, int height, int bpp, Uint32 flags) { + // Vita requires resolution to be divisible by eight + width-=width%8; + height-=height%8; + SDL_Surface *screen = SurfaceSdlGraphicsManager::SDL_SetVideoMode(width, height, bpp, flags); if (screen != nullptr) { -- cgit v1.2.3