From 43047988e507799d7d5bbcd926c5d0b5b94fcdc1 Mon Sep 17 00:00:00 2001 From: Justin Weiss Date: Sun, 2 Aug 2020 22:04:52 -0700 Subject: Add an option to downscale hi-res views Some older devices that use gpu_unai don't have a high enough resolution to display all of the pixels in high-res mode. There's a setting in unai to skip rendering of these pixels, but it's not connected to the libretro frontend, and does not appear to be used in the gpulib implementation at all. This commit adds a gpu_unai setting, Enable Hi-Res Downscaling, that will enable pixel skipping and blit only the pixels actually rendered into a buffer no larger than 384x240. This buffer is then treated as the actual framebuffer by gpulib and the libretro frontend. --- plugins/gpu_unai/gpu.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'plugins/gpu_unai/gpu.h') diff --git a/plugins/gpu_unai/gpu.h b/plugins/gpu_unai/gpu.h index eade2a8..f5eb69b 100644 --- a/plugins/gpu_unai/gpu.h +++ b/plugins/gpu_unai/gpu.h @@ -38,6 +38,10 @@ struct gpu_unai_config_t { // Normally 0. Value '1' will skip rendering // odd lines. + uint8_t scale_hires:1; // If 1, will scale hi-res output to + // 320x240 when gpulib reads the frame. + // Implies pixel_skip and ilace_force + // (when height > 240). uint8_t lighting:1; uint8_t fast_lighting:1; uint8_t blending:1; -- cgit v1.2.3