Provenance-Emu / Provenance

iOS & tvOS multi-emulator frontend, supporting various Atari, Bandai, NEC, Nintendo, Sega, SNK and Sony console systems… Get Started: https://wiki.provenance-emu.com |
https://provenance-emu.com
Other
5.93k stars 684 forks source link

EU PSX games are stretched/squished #877

Open illando opened 6 years ago

illando commented 6 years ago

Provenance is probably using some wrong video aspect ratio parameters for PSX emulation. Here you will find some screenshots I created to compare the same game using the Mednafen core on Provenance and OpenEmu.

game_prov game_openemu vs_prov game2_prov game_2_openemu vs2_prov

#

APP VERSION

APP SOURCE

INSTALLED BY

PLATFORM

iOS/tvOS VERSION


🚫 We DO NOT support unofficial builds installed from 3rd-party sites. (Official Install)
Need help or have a suggestion? Join our Official Discord

jsxn commented 6 years ago

It clearly says we DO NOT support unofficial builds in the bottom of the text of the github issue and that’s what you checked off 🤨

sevdestruct commented 6 years ago

@illando closing until you use an official build to report bugs about (will reopen if you find it on current official beta, from us)

illando commented 6 years ago

Guys, I don't want to be polemic, but, why put in the flag list "Other (Unofficial)" if It's not possible to post about that. I read the advice says that you DO NOT support it but when I saw the flag, I thought you started to consider also the unofficial builds, and that maybe the advice was not updated.

I really apologize for wasting your time.

JoeMatt commented 6 years ago

Well it comes down to preference, OpenEMU sets a 4x3 ratio, we set a 3x2, I don't remember why. Someone way back when we were testing PSX said it was correct and that's what it was set to.

There's also the ability to let Mednafen set the resolution. This is the code in question in MednafenGameCore.mm

        // Note: OpenEMU sets this to 4, 3.
        mednafenCoreAspect = OEIntSizeMake(3, 2);
        //mednafenCoreAspect = OEIntSizeMake(game->nominal_width, game->nominal_height);

You can either set it to 4,3, or change line 2 to commented and 3 to uncommented and see how mednafen handles it.

illando commented 6 years ago

Hi guys, I did some test with an official sideloading installation, so I think now you can reopen this isuue. As JoeMatt said it's something written in Provenance code, so I can confirm the problem is still there in the official release.

@JoeMatt I don't know who suggested the 3x2 ratio, but it's basically wrong. PSX was meant to be played on a TV, which is a 4:3 aspect ratio (320x240) and also if some games contains some movie cutscenes that don't respect that ratio, they'll be always stretched out to fit a 4:3 TV output. I also tested the two Retroarch iOS cores, PCSX and Beetle and they also use 4x3 (like Openemu). I understand your suggestion to modify the code by myself, but I think you should update it in the official release, so people that can not install Xcode on a mac (like me) and are using a Side-Loading installation can start to visualise PSX games in a correct way.

Thanks a lot.

sevdestruct commented 6 years ago

official sideloading means you are only using 1.4, current bug reporting is only for 1.5 beta as we won't be releasing patches to 1.4 at this time. …you can continue this conversation Discord, if you want.

sevdestruct commented 6 years ago

Reopening, to aid with citation of correct aspect (or intent from back then to let system aspect stretch to 4:3 as was often the case) feel free to link us info @illando …

sevdestruct commented 6 years ago

Sorry, @illando, but these are set to 4:3 which is demonstrably wrong, and it's obvious to me…

4:3

img_1382 img_1383 img_1384 img_1385

…I don't even have to overlay a point of reference for proportions to know this is wrong visually.

sevdestruct commented 6 years ago

3:3 as it was set, is quite close… might be a hair off.

3:2

image image

sevdestruct commented 6 years ago

So, though it is definitely not 4:3, it's not quite 3:2 either…

3:2

image

It's actually (thanks @illando)…

10:7

image

image

sevdestruct commented 6 years ago

So the ratio is solved (10:7), but the stretching of EU games (PAL), is not. though it was a misnamed forced BIOS issue, but @illando informed me that he doesn't have this issue with libretro using same BIOS.. so i guess that rules that out?

USA WipeOut

all fine here. image image image

EU Wipeout

squished/stretched image image image

JoeMatt commented 6 years ago

I'm aware that that tube TVs are 4x3, I'm old enough to have owned a few. You also have to contend with overscan and the fact that CRTs don't have pixels in the same sense as a HDTV or computer screen, they're staggered and rectangular. The ratio is meant to match the internal rendering not the output. SMS uses 4/2.55 but also outputs to a 4x3 CRT.

JoeMatt commented 6 years ago

libretro uses a custom version of mednafen so all bets are off on what they're doing by the way.

The BIOS's are configured correctly,

    MDFNI_SetSetting("psx.bios_jp", [[[biosPath stringByAppendingPathComponent:@"scph5500"] stringByAppendingPathExtension:@"bin"] UTF8String]); // JP SCPH-5500 BIOS
    MDFNI_SetSetting("psx.bios_na", [[[biosPath stringByAppendingPathComponent:@"scph5501"] stringByAppendingPathExtension:@"bin"] UTF8String]); // NA SCPH-5501 BIOS
    MDFNI_SetSetting("psx.bios_eu", [[[biosPath stringByAppendingPathComponent:@"scph5502"] stringByAppendingPathExtension:@"bin"] UTF8String]); // EU SCPH-5502 BIOS

Mednafen tries to auto determine the location, and then defaults to NA if it doesn't know.

I can't help without have a log of some sort saying if it failed to auto detect and chose the default, cause I can't (or won't) fix that as it's a Mednafen or ROM issue then. Still could be the wrong BIOS too.

sevdestruct commented 6 years ago

As am I, @JoeMatt, as I bet goes the same for our Italian friend… —that internal rendering is now a match: @illando provided this to help me, and verification is in the images: True Resolution of PSX

320x224 = 10:7 …the 3:2 we had would equal 320:213

Anyway…I meant to post images fgor @illando's issue reproduced on my devices — but was doing quickly before work, but i'll a,lso get you a log…

…the problem @illando as actually reporting against is noticeably different then the above, (reproduced images now above playing EU title against USA version) it just so happened that also our internal ratio was just a little off, noticed by chance.

illando commented 5 years ago

Now that Mednafen core is updated to 1.21.3 (same as Openemu) I tested it again to verify if the problem is stille there, and unfortunately is not solved (in Openemu the same roms are still not stretched). As @JoeMatt already said libretro uses a custom version of Mednafen,so I had the idea to test this version of Mednafen for OSX found at this link here. It's old (version 0.9.26 for Snow Leopard) but can still run in osx 10.13. Also using it the stretched video problem is not present. Here's a screenshot comparison:

Unfortunately it seems just related to Provenance :( comparison

illando commented 5 years ago

@sevdestruct @JoeMatt Guys, I have an update about this issue. It seems the problem is totally related to Mednafen that also on the PC side can't render video of PAL and NTSC games at the same ratio. I found this Mednafen forum link: https://forum.fobby.net/index.php?t=msg&goto=5661& Also on PC, the only way to fix the problem, is tho demand MedGUI (and not the Mednafen core) to use a different ratio for PAL games cutting some of the top/bottom black bars out of the device display. Now that Sev finally found the correct ratio for NTSC games would be possible to find the correct one also for PAL and make Provenance automatically choose between the two options based on the type of game you are launching?