Homebrew TWPatcher - DS(i) mode screen filters and patches

  • Thread starter Sono
  • Start date
  • Views 755,849
  • Replies 2,428
  • Likes 102

Are you interested in a complete replacement of TwlBg which includes all patches?

  • Yes, I don't care how broken it will be!

    Votes: 188 79.3%
  • No, I don't want to use even more broken stuff

    Votes: 20 8.4%
  • Yes, but only in GBA mode, because I play DSi exclusives

    Votes: 12 5.1%
  • No, because I only use DS and DSi mode

    Votes: 17 7.2%

  • Total voters
    237
  • Poll closed .

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,184
Trophies
1
XP
3,409
Country
Spain
GBA's vertical resolution is 160. 3DS's vertical res. is 240. Only 1,5 times.

You'd be leaving huge chunks of output outside of your view.

The most you can do (as far as I know) is use a filter, or mix of filters. On GPSP I got Bilinear + Normalx2/Scalex2 to make it somewhat okay, but you are not getting clean, sharp pixels and a larger output.
 
  • Like
Reactions: Sono

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,825
Trophies
2
Location
home
XP
9,376
Country
Hungary
well that sucks, any way you think it can be unbroken?
Post automatically merged:

any possibility to implement 2x integer scaling (nearest neighbour) for gba?

No, it can't be unbroken. This logic is hardcoded into the GPU circuitry. Besides, there is already a filter which simulates how it would look if nearest GPU scaling wasn't broken.

Also just like the others said, 2x would be cropping the GBA image to 180x120 out of the 240x160, so you'd miss out on quite a lot of the image.
 

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,184
Trophies
1
XP
3,409
Country
Spain
Look, instead of asking you could experiment and try stuff to see what adapts to you the best with what we can do currently (or at all, I guess).

As I said, GPSP on RetroArch provides the most variety in filters while also giving good performance, contrary to mGBA that has performance issues unfortunately.

I'll leave here a few screenshots of the different filters and their results.

01-1 Original.png

05-1 Unfiltered.png

03-1 Normalx2.png

04-1 Scalex2.png

02-1 4GridDark.png

I have to say the last filter is slightly modified by me, as the ones that come with RetroArch have very white-ish lines and I wanted something darker. The grid kinda helps but it's obviously not designed for this use.


Nothing is ideal, but at least there are options. If someone knows of more filters out there compatible with the 3DS it'd be nice to know, but I doubt it.

Scalex2 smooths out things fine enough, gives the picture a more rounded look that works fine enough for a lot of games, but games with very tiny text or sprites, like the GBA Final Fantasy ports can become rather annoying to read. Normalx2 might help there.

Other filters are either too close to the ones mentioned, or way too blurry to consider for me.

I'd like to put a screenshot of the bigger output of OPEN_AGB_FIRM but I think you can't make screenshots there.

The original aspect ratio ins't terrible, and I might prefer it depending on the game but I tend to need a few minutes to get used to how small is in comparison with 3DS software. Adjusting to DS isn't nearly as hard though...

Oh, and using the filters without Bilinear tends to be a horrible idea, just a warning.
 
  • Like
Reactions: Arcano_cz and Sono

selcuk

Well-Known Member
Newcomer
Joined
Oct 3, 2015
Messages
83
Trophies
0
Age
33
XP
257
Country
Ah, there is none for GBA because it looks absolutely awful, so I've removed it. For DS there is "Zero interpolation (double pixel)".
is zero interpolation for ds simulating integer scale or non integer nearest neighbour?
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,825
Trophies
2
Location
home
XP
9,376
Country
Hungary
Look, instead of asking you could experiment and try stuff to see what adapts to you the best with what we can do currently (or at all, I guess).

As I said, GPSP on RetroArch provides the most variety in filters while also giving good performance, contrary to mGBA that has performance issues unfortunately.

I'll leave here a few screenshots of the different filters and their results.






I have to say the last filter is slightly modified by me, as the ones that come with RetroArch have very white-ish lines and I wanted something darker. The grid kinda helps but it's obviously not designed for this use.


Nothing is ideal, but at least there are options. If someone knows of more filters out there compatible with the 3DS it'd be nice to know, but I doubt it.

Scalex2 smooths out things fine enough, gives the picture a more rounded look that works fine enough for a lot of games, but games with very tiny text or sprites, like the GBA Final Fantasy ports can become rather annoying to read. Normalx2 might help there.

Other filters are either too close to the ones mentioned, or way too blurry to consider for me.

I'd like to put a screenshot of the bigger output of OPEN_AGB_FIRM but I think you can't make screenshots there.

The original aspect ratio ins't terrible, and I might prefer it depending on the game but I tend to need a few minutes to get used to how small is in comparison with 3DS software. Adjusting to DS isn't nearly as hard though...

Oh, and using the filters without Bilinear tends to be a horrible idea, just a warning.

Huh, does GPSP use GPU for drawing the image? That "unfiltered" one especially grabs my attention, as you can see the fuzzyness caused by the way the GPU handles nearest upscaling.

Also that Normalx2 looks really good, makes me wonder how there is enough CPU cycles to handle the upscaling, especially considering that just scrolling a 16bit framebuffer console takes an extremely long time...

is zero interpolation for ds simulating integer scale or non integer nearest neighbour?

If it was integer scale at 2x, it would be cropped to 160x120 out of the 256x192, which is a LOT of the image missing. It's 1.25x nearest, with the 4th and 5th pixels being the same in each direction (upscale ratio is 5 pixels output from 4, as in 1.25x).
 

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,184
Trophies
1
XP
3,409
Country
Spain
I honestly don't know how RetroArch/GPSP does it, but you can input whatever aspect ratio you want.

Do you think a smaller scale than 1.5 would look better under these filters?

I always keep flipping between Normal and Scale, it's hard to choose for me.

Some of the filters included in RetroArch do affect the performance, but none of the ones I mentioned here seem to affect it, I have not experienced it on any test.
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,825
Trophies
2
Location
home
XP
9,376
Country
Hungary
I honestly don't know how RetroArch/GPSP does it, but you can input whatever aspect ratio you want.

Do you think a smaller scale than 1.5 would look better under these filters?

I always keep flipping between Normal and Scale, it's hard to choose for me.

Some of the filters included in RetroArch do affect the performance, but none of the ones I mentioned here seem to affect it, I have not experienced it on any test.

I think that 1.2x (6/5) would look better for both DS and GBA in terms of scaling, but it wouldn't fill the entire screen, and it's still too small because even fully filling the screen it is a bit too small too, probably because the GBA SP in particular had a bigger screen than the 3DS bottom screen.
 

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,184
Trophies
1
XP
3,409
Country
Spain
I did look for comparison photos and while I did not found numbers,a photo shows that the SP model is a bit larger than the original model.

I also found out that when non-xl screens play 1:1 GBA games the picture is smaller than on an original GBA, while XL models are the same or very very close.

Edit: I forgot to add a screen capture of mGBA, as it has hands down the best "full screen" picture out of any option, it's just unfortunate it also has not great performance... I'll add one later.

Edit: Oh, how interesting! It turns out mGBA runs at 800x240, not the usual 400x240. Could it might be the reason for the performance?

Regardless, here's a comparison shot for the above:

mGBA 3DS original output.png

mGBA 3DS output as it should be seen.png

I'll leave also an extra shot from Mario & Luigi, just to show another game.
mGBA 3DS Mario & Luigi.png

As you can see, it is very impressive, but I guess using the 800 mode helps? I wonder how it would look on 400 mode, an if doing that the performance would improve.

Oh, and by the way, I tried the new feature in OPEN_ABG_FIRM for borders. Converting to bgr is a bit annoying but after seeing how correctly, it works really nice! Thank you for working on that.
 
Last edited by Maeson,
  • Love
Reactions: Sono

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,825
Trophies
2
Location
home
XP
9,376
Country
Hungary
This is not a release build, don't use any patch other than rtcom.

Added experimental 4grid filters, I need some feedback.

It definitely needs tweaking, but I need to know how it looks to others as well, and if someone very well versed in emulator filters could chime in to help me tweak it so it doesn't look so off.
 

Attachments

  • TWPatch.zip
    1.1 MB · Views: 40
  • Like
Reactions: DSoryu and YuseiFD

mr_zoodoo

New Member
Newbie
Joined
Nov 13, 2023
Messages
2
Trophies
0
Age
20
XP
9
Country
Ireland
Yo, how I've been trying to apply the blue light filter but I don't seem to be getting it to work. Anyone know how to do it?
 

Sono

cripple piss
OP
Developer
Joined
Oct 16, 2015
Messages
2,825
Trophies
2
Location
home
XP
9,376
Country
Hungary
is it not possible to scale ds or gba to the full 800x240 resolution of the 3ds?

It is possible with GBA mode, not with DS mode though.

Not possible at all in TwlBg, it has to be fully custom.

Yo, how I've been trying to apply the blue light filter but I don't seem to be getting it to work. Anyone know how to do it?

Enabled in Luma? Power off, hold SELECT, power on, enable patching and module loading, START to save.
 

mr_zoodoo

New Member
Newbie
Joined
Nov 13, 2023
Messages
2
Trophies
0
Age
20
XP
9
Country
Ireland
It is possible with GBA mode, not with DS mode though.

Not possible at all in TwlBg, it has to be fully custom.



Enabled in Luma? Power off, hold SELECT, power on, enable patching and module loading, START to save.
Yes they're enabled but it doesn't seem to be working :/
 

enpeaphor

Member
Newcomer
Joined
Aug 17, 2021
Messages
14
Trophies
0
XP
500
Country
United Kingdom
I've had a search through the thread and found - this post - where you mention PICA200 has a fixed pixel shader, is this only whilst scaling?
If not, is it possible to implement a shader for 'real' GBA and DS-Phat color correction, such as this

Also curious what the use case for 4grid filters are, is it to replicate the DS pixel grid when scaling?
 

The_Box

New Member
Newbie
Joined
Jan 6, 2024
Messages
2
Trophies
0
Age
22
XP
12
Country
Russia
Hi! As I did't find any GitHub repo for this to make a feature request, I'll ask here. Is it even possible to rotate both screens for games that work in book mode? Like sudoku by my brain academia
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: I really don't want to buy this fap tab...