• Login
  • Register
  • Dolphin Forums
  • Home
  • FAQ
  • Download
  • Wiki
  • Code


Dolphin, the GameCube and Wii emulator - Forums › Dolphin Emulator Discussion and Support › Development Discussion v
« Previous 1 2 3 4 5 … 117 Next »

Gamecube Aspect Ratio
View New Posts | View Today's Posts

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Threaded Mode
Gamecube Aspect Ratio
10-23-2022, 05:53 PM
#1
TheMrGmk Offline
Junior Member
**
Posts: 6
Threads: 1
Joined: Oct 2022
Hey everyone ! I don't know if this is the right place (I'm new), but I would like to share my findings about aspect ratio for certain gamecube games. After playing metroid prime on dolphin, I always felt that something was slighty wrong compared to my various playthroughs on the original gc. Never quite understood what was wrong, but yesterday I finally realized that everything is juuuust a little squashed. You can notice that with the aim reticule when you lock on enemies, it's not a circle but an oval, even if it's not easy to notice that.
Interested, I started searching for original screenshot from back in the day of the game and found out that my impressions was actually correct, aspect ratio in pics coming from official sources was different. After some investigations, it turned out that metroid prime, among other games (I found a list here: https://orcaapp.herokuapp.com/gc) doesn't have a native resolution of 4:3, but a peculiar 646x480, aka 4.04:3 according to my calculations. No aspect ratio option in dolphin displays that resolution correctly. Even using gecko codes or the widescreen hack, the game becomes 16:9, while still keeping the incorrect squashed proportions of game elements, hub etc. I was wrapping my mind on how to fix this issue and after hours of trial and error, maths etc I managed to find a solution to play the game in full screen, 16:9 (well, sorta) with exactly the same proportioned image quality of the original game.

First, you have to use the gecko code for widescreen (using the widescreen hack will force real 16:9, which destroys the purpose because that aspect ratio has incorrect proportions).
The gecko code is this one (for whoever whants to try):

Spoiler:
F6000001 80008180
FF401090 EF210032
D2000000 00000002
3DC04000 91C20000
C3420000 00000000
D200000C 00000002
3DC04000 91C20000
C3420000 00000000
E0000000 80008000
F6000001 80008180
ED6A4824 ED080172
D2000000 00000004
3DC03FAA 61CEAAAB
91C20000 C2620000
ED330272 ED6A4824
60000000 00000000
E0000000 80008000

Open dolphin, and under graphics config select "Stretch to window" under aspect ratio. (Gecko code allow us to actually strech the rendered game, while widescreen hack has fixed aspect ratio).

Then, set a custom resolution through nvidia control panel (or you corresponding software, I have a nvidia card). The resolution you have to set is 1920x1010 (I calculated this resolution by doing adjustments in window mode, using the above mentioned screenshots and some new screenshot I took of dolphin running at 646x480 res as reference, aligning new screenshot above those, try after try until the hud was pixel perfect)
Open the game in fullscreen mode. Now you can enjoy the game correctly proportioned in widescreen.
I don't know if dolphin's developers are already aware of this/interested about this topic, but if there's a way this can reach them is this forum and that would be great, as I think allowing more practical ways to adjust the aspect ratio to be more faithful to the original machine would be great (similar to the 4:3, 8:7 conversation about snes).
Doing this was quite a mess but I hope someone find these informations useful
Cheers !
Find
Reply
10-24-2022, 10:52 AM
#2
One More Try Offline
Posting Freak
*****
Posts: 888
Threads: 23
Joined: Dec 2014
https://github.com/dolphin-emu/dolphin/pull/10722

My shader was made for this. I'm not sure if it can do exactly what you've done though. Someone would have to test it.
Find
Reply
10-25-2022, 04:07 AM
#3
TheMrGmk Offline
Junior Member
**
Posts: 6
Threads: 1
Joined: Oct 2022
(10-24-2022, 10:52 AM)One More Try Wrote: https://github.com/dolphin-emu/dolphin/pull/10722

My shader was made for this. I'm not sure if it can do exactly what you've done though. Someone would have to test it.

Awesome ! It's good to know that someone else already noticed this particular dolphin behaviour, I did some research before trying to fix the inaccurate aspect ratio myself but couldn't find anything meaningful, only some old posts about the crop function that doesn't solve the issue. Didn't even come close to stumble upon your shader, that's a shame.
I'll give it a shot and compare the results to my solution, I'll update my findings here asap.
Find
Reply
10-25-2022, 11:37 AM
#4
One More Try Offline
Posting Freak
*****
Posts: 888
Threads: 23
Joined: Dec 2014
Thanks! Check with the widescreen code active too. You probably need it still.
Find
Reply
10-25-2022, 12:57 PM (This post was last modified: 10-25-2022, 10:44 PM by TheMrGmk.)
#5
TheMrGmk Offline
Junior Member
**
Posts: 6
Threads: 1
Joined: Oct 2022
Ok, I've done some testing and here's what I have to say:

You're shader works WONDERFULLY for maintaining the original aspect ratio in the 4:3ish format (aka the original one)

Here's a screenshot of the game with my method:
https://imgur.com/YKqNTDA

And here a screenshot with your integer upscaling shader. I had to fiddle a little with the slider options, but:
https://imgur.com/MFyAVVu

As you can see the hud and lock on reticule are 99.9% exactly the same so I'd say both your shader and my method achieve a pretty perfect preservation of the original aspect ratio.

Problems arise when I try to use your shader with a widescreen resolution (either with the widescreen hack or the gecko code). Probably because integer upscales the original resolution of the game while preserving its aspect ratio and, well, widescreen is simply not a part of the equation.

Better result I got with some fiddling was this:
https://imgur.com/72paSrx

As you can see, squashed orizontally by a lot. Not satisfied, I did some edits to your shader to change the value for two sliders step amount ("integer scale - no higher than IR" and "scale width"), 1.0 was too much and the resulting image become either orizontally or vertically squashed. I changed both the step amount from 1.0 to 0.00390625.

This is the result:
https://imgur.com/yyXKLhc

Off by 1 or 2 pixels, if we want more accuracy we should go with even smaller step amount factors.
These were the settings of the shader for this screenshot:
https://imgur.com/S7KG1DG


I could get a much more precise aspect ratio with less step amounts by going to "use non-integer widht" tab and turning on "stretch width to window", but unfortunately the game is decentered:
https://imgur.com/SDWs6iy

My conclusions are that if we are using your shader and we want a widescreen aspect ratio we have to fiddle with settings a lot and we still need to have reference pics.
I'm no programming expert and you obviously know your own shader better than me, do you think it could be possible to automate the process for getting widescreen as it already is for "4:3" ? Like, I don't know, add a preset chunk of rendered pixels on both sides while not touching the aspect ratio.
Find
Reply
10-25-2022, 06:14 PM
#6
One More Try Offline
Posting Freak
*****
Posts: 888
Threads: 23
Joined: Dec 2014
Can you use the gecko code then go to graphics ->advanced -> dump xfb target? It'll make an xfb image on each frame, so be careful it doesn't spam you. You can pause and use frame advance. Then grab it from the dolphin user data folder dump/textures/ and post it?

The shader only transforms the xfb image. I'll have to see the base dimensions for widescreen xfb.
Find
Reply
10-26-2022, 06:32 PM
#7
TheMrGmk Offline
Junior Member
**
Posts: 6
Threads: 1
Joined: Oct 2022
Sure ! I'll do it as soon as I can Smile
Find
Reply
« Next Oldest | Next Newest »


  • View a Printable Version
Forum Jump:


Users browsing this thread: 1 Guest(s)



Powered By MyBB | Theme by Fragma