Is it possible to set a maximum aspect ratio?

Hey, I tend to play my 2D games with 1:1 pixel aspect ratio - and yes, I know that this is controversial and that games were technically designed for 4:3 monitors in the 80s and 90s, but to my eyes the majority of games look more “correct” with square pixels then when stretched or sqished to 4:3. I will die on that hill! Recently I switched from Beetle PSX to Duckstation in RetroArch and found that it is much more compatible with 1:1 PAR than the Mednafen core. The Beetle PSX and especially Saturn cores seem to have severe problems displaying games in PAR.

Anyway, while I really enjoy playing games like Parodius or SOTN in 8:7, some games on the PlayStation use a sort of ultra-wide aspect ratio that looks completely off in 1:1 PAR. For example Mega Man X6: the gameplay looks fine in 1:1 PAR (10:7 with overscan cropped in Duckstation), but the title screen and cutscenes use some sort of widescreen aspect ratio that looks off and distorted. I was wondering if it was possible to set a maximum resolution of 10:7 - so that everything that gets wider than this aspect ratio gets squished down to 10:7. I’m aware that this is not possible with RetroArch’s video settings, but is there a shader with which I can accomplish this? I know that this is an odd request, but hopefully someone can point me into the right direction anyway! :slight_smile:

The easiest way to do this would be by creating a 10:7 resolution for your display and use that in retroarch. On a 1080p screen for example you might create a 1544x1080 resolution and set the GPU (or your display if you don’t use GPU scaling) to not scale it.

You can set a config aspect in a per game override. For example I have RetroArch\config\DuckStation\Crash Bandicoot (USA).cfg which contains:

aspect_ratio_index = "20"
video_aspect_ratio = "1.48125"

You’d just convert your 10:7 into a decimal, so 1.428571. The config ratio is forced no matter what resolution mode the PSX is running in.

3 Likes

@RealNC This doesn’t seem to work - it just squeezes the gameplay into a smaller letterbox, with the same aspect ratio.

@Awakened Yeah, I’ve used per-game overrides so far. I was just wondering if it could be solved more elegantly with a shader. My problem is that I wanna avoid 8:7 or 4:3 content to be stretched to 10:7, I just want everything that gets wider to be squeezed down to 10:7. A lot of PSX games vary wildly with their in-game resolutions, especially collections like the Konami SHMUP deluxe versions, so setting a fixed resolution per game is sometimes problematic.

Then I’d say you found a retroarch bug. It shouldn’t do that.

Shouldn’t this be 23?

23 is “Custom” which seems to be different. That one gives you an adjustable viewport with X, Y, H and W values. Config only uses a single decimal value.

2 Likes

Hmmm. :thinking: I thought config was driven by the %system%libretro.cfg. Good to know!