From 0394e4bb8ee35981ad1a39818e21ba23faf80db6 Mon Sep 17 00:00:00 2001 From: Valeri Date: Sat, 9 Oct 2021 20:13:45 +0300 Subject: vic: Allow surface to be higher than frame Touhou Genso Wanderer Lotus Labyrinth R decodes 1920x1080 videos into 1920x1088 surface. Only allow mismatch for height, since larger width would result in increasingly offset rows and somewhat defeat entire purpose of this check. --- src/video_core/command_classes/vic.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/video_core/command_classes/vic.cpp b/src/video_core/command_classes/vic.cpp index 51f739801..dc768b952 100644 --- a/src/video_core/command_classes/vic.cpp +++ b/src/video_core/command_classes/vic.cpp @@ -88,9 +88,10 @@ void Vic::Execute() { const u64 surface_width = config.surface_width_minus1 + 1; const u64 surface_height = config.surface_height_minus1 + 1; if (static_cast(frame->width) != surface_width || - static_cast(frame->height) != surface_height) { + static_cast(frame->height) > surface_height) { // TODO: Properly support multiple video streams with differing frame dimensions - LOG_WARNING(Debug, "Frame dimensions {}x{} do not match expected surface dimensions {}x{}", + LOG_WARNING(Debug, + "Frame dimensions {}x{} can't be safely decoded into surface dimensions {}x{}", frame->width, frame->height, surface_width, surface_height); return; } -- cgit v1.2.3