Homebrew Official Retroarch WiiU (wip.)

eyeball226

Well-Known Member
Member
Joined
Jan 11, 2009
Messages
160
Trophies
1
XP
390
Country
The game output isn't always at 480p. For example, a game is 256 x 244 or something, then you choose whatever scaling, so if you choose 1:1 scaling, the game output is still 256 x 244. The GPU takes that 256 x 244 texture and fills the gamepad and TV screen with the 256 x 244 texture, based on the height of it. So if the height is 244, the width and height would be scaled at a factor of 480/244 for the gamepad and 720/244 for the TV. It isn't scaling the 480p texture of the gamepad to the size of the TV, it is scaling the size of the game output to fill both the gamepad and TV.

If you don't want it filling, then change the setting in the video driver.

Ok, I think I understand now. But the numbers referenced in the video settings are still treating 480 as the full height even if the texture is being separately mapped to the TV and gamepad. So if it's a SNES game with a vertical resolution of 224, 3x would be 672 which should fit my TV with black bars - however that setting crops the image off the top and bottom.
So what do I need to do to get an integer scaled picture on the TV? Because setting it to 1x gives me 1x pixels on the gamepad and 1.5x on the TV. 2x gives me 3x on the TV, so how do I get 2x?

p.s. Which setting in the video driver?
 

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
Ok, I think I understand now. But the numbers referenced in the video settings are still treating 480 as the full height even if the texture is being separately mapped to the TV and gamepad. So if it's a SNES game with a vertical resolution of 224, 3x would be 672 which should fit my TV with black bars - however that setting crops the image off the top and bottom.
So what do I need to do to get an integer scaled picture on the TV? Because setting it to 1x gives me 1x pixels on the gamepad and 1.5x on the TV. 2x gives me 3x on the TV, so how do I get 2x?

p.s. Which setting in the video driver?
Set the correct ratio in the video driver.
 

MaitreLLD

Well-Known Member
Member
Joined
Dec 15, 2016
Messages
134
Trophies
0
Age
39
XP
104
Country
France
Ok, I think I understand now. But the numbers referenced in the video settings are still treating 480 as the full height even if the texture is being separately mapped to the TV and gamepad. So if it's a SNES game with a vertical resolution of 224, 3x would be 672 which should fit my TV with black bars - however that setting crops the image off the top and bottom.
So what do I need to do to get an integer scaled picture on the TV? Because setting it to 1x gives me 1x pixels on the gamepad and 1.5x on the TV. 2x gives me 3x on the TV, so how do I get 2x?

p.s. Which setting in the video driver?
Well, all of this is weird. I never touched any video option and I don't see any scaling artifact neither on my TV nor on my gamepad. Maybe my eyes are not good enough, but usually these artifacts are quite ugly so easy to spot.

There might be some linear interpolation behind that that my eyes can't spot.

Now I do have black bars on the TV on some cores of course (like the SNES and its weird resolution), but not cropping: the whole image of the whole game is there, on both screens.

PS : funnily enough, the real SNES on a real old TV had some cropping indeed, if I remember correctly !
 
Last edited by MaitreLLD,

eyeball226

Well-Known Member
Member
Joined
Jan 11, 2009
Messages
160
Trophies
1
XP
390
Country
Set the correct ratio in the video driver.

You mean the aspect ratio? I do, that doesn't seem to change the fact that the integer scaling options are targeting a 480p resolution.

Well, all of this is weird. I never touched any video option and I don't see any scaling artifact neither on my TV nor on my gamepad. Maybe my eyes are not good enough, but usually these artifacts are quite ugly so easy to spot.

There might be some linear interpolation behind that that my eyes can't spot.

Now I do have black bars on the TV on some cores of course (like the SNES and its weird resolution), but not cropping: the whole image of the whole game is there, on both screens.

PS : funnily enough, the real SNES on a real old TV had some cropping indeed, if I remember correctly !

What resolution is your TV? Assuming it's 720p or 1080p or more, try the following:

Load up a SNES game.
Go into settings -> video.
Change aspect ratio to 'custom'.
Turn integer scale on.
Now change custom viewport width and height to 3x (because 3*224 is only 672 so it should fit well within 720p, right?).
Now observe the amount of cropping that is happening.
Now change custom viewport width and height to 2x and see how it almost fills the screen at 448 pixels height.
This is what I've been talking about, if you see something different then I wonder what I've got set wrong.

I know that real consoles usually had stuff cropped by the overscan, but that doesn't change the fact that there's something wrong with the maths here. The emulator is targeting a 480p screen in terms of its scaling calculations and it means that all the integer scaling options are messed up. There's no way to get a clean 2x scale on a 720p TV - the 1x option gives 1.5x and the 2x option gives 3x.
 

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
You mean the aspect ratio? I do, that doesn't seem to change the fact that the integer scaling options are targeting a 480p resolution.



What resolution is your TV? Assuming it's 720p or 1080p or more, try the following:

Load up a SNES game.
Go into settings -> video.
Change aspect ratio to 'custom'.
Turn integer scale on.
Now change custom viewport width and height to 3x (because 3*224 is only 672 so it should fit well within 720p, right?).
Now observe the amount of cropping that is happening.
Now change custom viewport width and height to 2x and see how it almost fills the screen at 448 pixels height.
This is what I've been talking about, if you see something different then I wonder what I've got set wrong.

I know that real consoles usually had stuff cropped by the overscan, but that doesn't change the fact that there's something wrong with the maths here. The emulator is targeting a 480p screen in terms of its scaling calculations and it means that all the integer scaling options are messed up. There's no way to get a clean 2x scale on a 720p TV - the 1x option gives 1.5x and the 2x option gives 3x.
Integer Scaling 3x and I have black bars on top and bottom on the TV as well as the Gamepad, not sure why you can't seem to set it up right.

Maybe if you'd set it up with core provided ratio like I've said before, it would work for you.
 
Last edited by brienj,

eyeball226

Well-Known Member
Member
Joined
Jan 11, 2009
Messages
160
Trophies
1
XP
390
Country
Integer Scaling 3x and I have black bars on top and bottom on the TV as well as the Gamepad, not sure why you can't seem to set it up right.

Maybe if you'd set it up with core provided ratio like I've said before, it would work for you.

Are you sure you set it up exactly as I said? Unless aspect ratio is set to 'custom' it will ignore the viewport height and width settings. If you have it set to custom then those settings will have a direct influence on the image size and you will see what I said.

I'm using this set up to demonstrate the flaw in the scaling maths, but even so, what if I don't want to use the core provided AR? The aspect ratio options are there because people have different preferences and set ups. I don't understand why you're fixated on me using your preferred option when I'm trying to explain a fundamental flaw in the maths used to calculate the integer scaling.
 

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
Are you sure you set it up exactly as I said? Unless aspect ratio is set to 'custom' it will ignore the viewport height and width settings. If you have it set to custom then those settings will have a direct influence on the image size and you will see what I said.

I'm using this set up to demonstrate the flaw in the scaling maths, but even so, what if I don't want to use the core provided AR? The aspect ratio options are there because people have different preferences and set ups. I don't understand why you're fixated on me using your preferred option when I'm trying to explain a fundamental flaw in the maths used to calculate the integer scaling.
You said it doesn't integer scale 3x, it does. You THINK that you have to set it up to custom, you do NOT. You choose ratio from the core, then set up the viewport to 960 x 720 and the integer scale to 3, and BOOM, my 720p TV has black bars on the top and bottom. You said this is impossible, I'm showing you that it isn't, and the core provided ratio IS the actual ratio, so why is that wrong? The image is 3x the original size and is 768 x 672, or (256x3) X (224x3). This is exactly what you were complaining you couldn't do, and I did it.

You must be setting the viewports to two different scales, and that's not what you do, or you will get the skewed results you are getting.
 
Last edited by brienj,

lordelan

Well-Known Member
Member
Joined
Jan 4, 2015
Messages
5,800
Trophies
1
Age
44
XP
6,568
Country
Germany
I made a custom boot screen and icon for RetroArch:
RetroArch for Wii U.png


I recommend using it with Haxchi to launch this.

However if anyone is still making native channel versions (or forwarders) for RetroArch, feel free to use my images as you like.

Also make sure to check my custom images for Mocha CFW and Haxchi in my signature. :)
 

Attachments

  • bootDrcTex.zip
    781 KB · Views: 136
  • bootTvTex.zip
    1.6 MB · Views: 143
  • iconTex.zip
    44 KB · Views: 130
  • title.zip
    125 bytes · Views: 129

Hielkenator

Well-Known Member
Member
Joined
Feb 7, 2010
Messages
4,210
Trophies
0
XP
679
Country
Netherlands
You mean the aspect ratio? I do, that doesn't seem to change the fact that the integer scaling options are targeting a 480p resolution.



What resolution is your TV? Assuming it's 720p or 1080p or more, try the following:

Load up a SNES game.
Go into settings -> video.
Change aspect ratio to 'custom'.
Turn integer scale on.
Now change custom viewport width and height to 3x (because 3*224 is only 672 so it should fit well within 720p, right?).
Now observe the amount of cropping that is happening.
Now change custom viewport width and height to 2x and see how it almost fills the screen at 448 pixels height.
This is what I've been talking about, if you see something different then I wonder what I've got set wrong.

I know that real consoles usually had stuff cropped by the overscan, but that doesn't change the fact that there's something wrong with the maths here. The emulator is targeting a 480p screen in terms of its scaling calculations and it means that all the integer scaling options are messed up. There's no way to get a clean 2x scale on a 720p TV - the 1x option gives 1.5x and the 2x option gives 3x.
SIGH!!

Make sure your tv is outputting it's native resolution and is NOT scaling to 16:9!

Samsungs have this option called screen fit.
This will ensure 1:1 pixel mapping.
If you are like me and want 4:4:4 subpixel mapping without any compression of bleu and red set your tv to PC mode.
You will get 1:1 pixels without compression or scaling.
Perfect results with RA for WiiU ( Not like RA Wii where you would have to set all cores up with custom viewport! Because of Wii weird 4:3 vs faux 16:9 ratio scaling. )

Do as people say on this thread and you will get the correct results you are after.
My geuss is, your TV setting are the reason of you problems.
 

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
SIGH!!

Make sure your tv is outputting it's native resolution and is NOT scaling to 16:9!

Samsungs have this option called screen fit.
This will ensure 1:1 pixel mapping.
If you are like me and want 4:4:4 subpixel mapping without any compression of bleu and red set your tv to PC mode.
You will get 1:1 pixels without compression or scaling.
Perfect results with RA for WiiU ( Not like RA Wii where you would have to set all cores up with custom viewport! Because of Wii weird 4:3 vs faux 16:9 ratio scaling. )

Do as people say on this thread and you will get the correct results you are after.
My geuss is, your TV setting are the reason of you problems.
I know he is creating his own problems, because if you just set it to core provided, and don't mess with anything else, it fills the TV and Gamepad with the exact same scaling, and it looks nice. IDK why someone wouldn't want to use all of their TVs real estate, but hey, who am I to judge?
 

Silent_Gunner

Crazy Cool Cyclops
Banned
Joined
Feb 16, 2017
Messages
2,696
Trophies
0
Age
29
XP
4,727
Country
United States
I just set this up on my Wii U last night, and the biggest problem I've encountered is the fact that controller settings are shared across emulators. As in, say I was playing Metal Slug, and wanted to change the default controls to Y to shoot, B to jump, and A for grenades. (the default control scheme doesn't work on that game for me) Thing is, this also changes the confirm and go back buttons for the GUI of the emulator itself, not to mention changing the controls for the other emulators within Retroarch.

What I want to know (and this is just the first of many questions, but this is the make it or break it one) is whether you can make the confirm and go back buttons on the menu consistent and whether you can have specific emulators have their own control configurations. The latter is a bigger problem than the first, though the former should NOT be an issue when making emulators like this, IMHO.
 

efen3001

Well-Known Member
Member
Joined
Apr 21, 2011
Messages
165
Trophies
0
XP
185
Country
United States
I just set this up on my Wii U last night, and the biggest problem I've encountered is the fact that controller settings are shared across emulators. As in, say I was playing Metal Slug, and wanted to change the default controls to Y to shoot, B to jump, and A for grenades. (the default control scheme doesn't work on that game for me) Thing is, this also changes the confirm and go back buttons for the GUI of the emulator itself, not to mention changing the controls for the other emulators within Retroarch.

What I want to know (and this is just the first of many questions, but this is the make it or break it one) is whether you can make the confirm and go back buttons on the menu consistent and whether you can have specific emulators have their own control configurations. The latter is a bigger problem than the first, though the former should NOT be an issue when making emulators like this, IMHO.
I love retroarch, but the controls and overlay (not featured yet) settings are way too complicated.
 
Last edited by efen3001,

MaitreLLD

Well-Known Member
Member
Joined
Dec 15, 2016
Messages
134
Trophies
0
Age
39
XP
104
Country
France
I'm genuinely interested in seeing these artefacts you see @eyeball226, just in case it's something I can't see on my own.
Could you take a screenshot or better yet, a picture, of it ? I think the title screen of Super Mario Bros. on the NES is good for that, the tiles of the ground are good victims of non-integer scaling. I really can't see it on my system (with core provided aspect ratio, bilinear filtering OFF, and funnily enough, whether integer scale is activated or not).

Edit: now that I look more into it it seems indeed that this is not pixel perfect, no matter what I do, a little bit as in the following image (the diagonal of the first SMB hill)
https://imgur.com/erGK8pb
It's not a photo of mine, it's taken from
https://github.com/libretro/libretro-fceumm/issues/41
but my system gives something in the same spirit (you can clearly spot some uneven pixels)

Same problem on the Gamepad though. Absolutely no settings can change that (no matter what the aspect ratio is, integer scale on or off + core options like overscan crop or not...), as if it would come from the Wii U itself.
 
Last edited by MaitreLLD,

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
I'm genuinely interested in seeing these artefacts you see @eyeball226, just in case it's something I can't see on my own.
Could you take a screenshot or better yet, a picture, of it ? I think the title screen of Super Mario Bros. on the NES is good for that, the tiles of the ground are good victims of non-integer scaling. I really can't see it on my system (with core provided aspect ratio, bilinear filtering OFF, and funnily enough, whether integer scale is activated or not).
Using the core provided ratio always looks the best, because of the way it is designed. There is no need for special settings at all, unless you just don't want it filling up the screen for whatever reason. The texture is the size of the game output, and the GX2 does all the stretching or shrinking of the texture to fit, but the texture used by the GX2 is the same size as the game itself.
 

MaitreLLD

Well-Known Member
Member
Joined
Dec 15, 2016
Messages
134
Trophies
0
Age
39
XP
104
Country
France
Yep I agree with that, this is the most accurate option we have, but see my edit just after that. It seems that there is a genuine problem at the very source even with that. I actually would like to see a similar photo from a real NES on a real CRT TV to see that hill, but apparently Retroarch in Windows makes that hill diagonal with even pixels...
PS : my TV isn't the cause, it's set on "screen fit" so doesn't stretch the signal it gets.
 
Last edited by MaitreLLD,

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
Yep I agree with that, this is the most accurate option we have, but see my edit just after that. It seems that there is a genuine problem at the very source even with that. I actually would like to see a similar photo from a real NES on a real CRT TV to see that hill, but apparently Retroarch in Windows makes that hill diagonal with even pixels...
PS : my TV isn't the cause, it's set on "screen fit" so doesn't stretch the signal it gets.
After seeing the link to the issue page, I see your real issue, you aren't using Nestopia.
 

MaitreLLD

Well-Known Member
Member
Joined
Dec 15, 2016
Messages
134
Trophies
0
Age
39
XP
104
Country
France
After seeing the link to the issue page, I see your real issue, you aren't using Nestopia.
Nope that's not me, and the aspect of that thing is the same on Nestopia or FCEUmm (the picture and the thread aren't mine).
Here is a picture of me with Nestopia (core provided ratio and didn't touch anything, but with integer scale on it looks quite similar, I'll post a second picture)
https://goo.gl/photos/V1RVfXddaQgnb9nJ6 (without integer scale)
https://goo.gl/photos/FVsqd1yYm11C7Dnm9 (with integer scale active)
Playing with cropping or not the overscan doesn't change anything btw

https://i.imgur.com/V20D5JP.jpg Apparently correct picture, taken from Retroarch Windows by some guy
 
Last edited by MaitreLLD,

brienj

Trying to avoid getting cancer
Member
Joined
Jan 3, 2016
Messages
1,232
Trophies
0
Website
twitter.com
XP
2,142
Country
United States
Nope that's not me, and the aspect of that thing is the same on Nestopia or FCEUmm (the picture and the thread aren't mine).
Here is a picture of me with Nestopia (core provided ratio and didn't touch anything, but with integer scale on it looks quite similar, I'll post a second picture)
https://goo.gl/photos/V1RVfXddaQgnb9nJ6 (without integer scale)
https://goo.gl/photos/FVsqd1yYm11C7Dnm9 (with integer scale active)
Playing with cropping or not the overscan doesn't change anything btw

https://i.imgur.com/V20D5JP.jpg Apparently correct picture, taken from Retroarch Windows by some guy
I never noticed, haven't played much, mostly always testing, but have you tried the 1:1 ratio with square pixels, maybe the core provided one is messed up in those cores.
 

MaitreLLD

Well-Known Member
Member
Joined
Dec 15, 2016
Messages
134
Trophies
0
Age
39
XP
104
Country
France
Hmm you might be right.
- If you set up integer scale and a custom aspect ratio of (2X) 480x480 (so not at all the NES ratio) it starts to be perfect on the gamepad.
- The GBA (mGBA) is perfect directly without any settings (nice !).
- SNES (Snes9X) is messed up as well. But differently. You have to set integer scale on and at 2X (512x478, not sure if this is the correct aspect ratio, but it's definitely not the core provided one) it starts to be perfect on the gamepad.

Strange observation: on both Snes9X and Nestopia, if you set integer scaling on and move up to a 4X resolution (thus you can't find the whole image of the game in the screen) it starts to be correct (whereas on the gamepad it's already correct at 2X) ! It's quite clear on A link to the past, once you're out of the house, just look at the bottom left corner of the house, you have a nice diagonal of pixels. At resolutions 1, 2, 3X it's messed up but at 4X, 5X (weirdly) and 6X it's good.

On Super Mario Bros (Nestopia), at 2X integer scale the Gamepad is good, at 4X the TV seems to be good (we can only see a few pixels of the hill so I can't guarantee it but it seems to be ok)

This actually kind of proves @eyeball226 theory : the 1.5 factor, once doubled, becomes integer again. Even though the fact that ALTTP on Snes9X is correct at 5X seems strange.

Moreover now that I think about it, I think Core provided res. by Snes9X is not at all the correct one whereas the integer scale (multiples of 256x239) are indeed a proper possible mode of the SNES. On the other hand for Nestopia it's the contrary. But for FCEUmm it's like the SNES, integer scaling proposed ones are correct and core provided is not.

So it's a whole mess, and now I think @eyeball226 was right from the beginning !

Edit : I filed a report
https://github.com/libretro/RetroArch/issues/4655
Feel free to contribute if you can explain it better !

Edit2 : @aliaspider answered, confirmed, and proposes to set the TV as the main screen for computations for now.
 
Last edited by MaitreLLD,
  • Like
Reactions: lordelan

SG854

Hail Mary
Member
Joined
Feb 17, 2017
Messages
5,215
Trophies
1
Location
N/A
XP
8,104
Country
Congo, Republic of the
Glad that the viewport calculations is now being set to TV instead of Gamepad. I was about jump in and defend @eyeball226 I knew he wasn't crazy. I also saw this problem when I was setting custom viewport to 1196x896, a 4x multiple of 299x224 which is the correct 4/3 aspect ratio (which I prefer over pixel perfect) for 1080p screens. The image was getting cropped off by a lot.

Before anyone argues me, because I know this is debated a lot, divide 4/3 you get 1.3333.
Divide 299/224 you get 1.3348 closest to 4/3. Getting close to the right proportions like you would on a crt tv.
Divide pixel perfect 256x240 you get 1.066 not 4/3.
Its all explained here https://forum.recalbox.com/topic/3494/overlays/39

Hopes this helps anyone wanting to get correct 4/3 aspect ratio once tv viewport calculations is implemented.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    ZeroT21 @ ZeroT21: :lol: