Hacking Possible to Disable the Wii's (De)Flicker Filter?

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
I couldn't find the place to edit using my method for Tennis, but it doesn't matter much because the way that SuperrSonic's cheat let me find works well anyway.

This string seems to work for several games, including Mario Tennis. I'm still testing it though.

Find: 94 21 FF E0 7C 08 02 A6 3C 80 80 17 90 01 00 24 93 E1 00 1C
Replace: 4E 80 00 20 7C 08 02 A6 3C 80 80 17 90 01 00 24 93 E1 00 1C

For those of you playing at home, 4E 80 00 20 means 'branch to link register' -- the last instruction executed at the end of a function. It's the instruction for 'return' or 'go back to whoever called this function'. From this you can tell where all the game's functions start and end.

The 94 21 FF E0 is preceded by a 4E 80 00 20, so 94 21 FF E0 is the first instruction. Replacing it with 4E 80 00 20 means we're inserting a 'return' as the first line and skipping this function entirely, so I'm guessing it's the function which sets the dark filter (unrelated to vfilter). I'm guessing it's something like a GXSetEpilepsyFilter function, for lack of better term.

@MaeseJesus: how did you discover this string? I'm curious to know more about this function and what it does exactly.
 
Last edited by NoobletCheese,

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,188
Trophies
2
XP
3,440
Country
Spain
Oh c'mon, I skipped that one because for the other three games I looked on were quite later on... I hate myself!

I found this string by looking at Wave Race's Gecko Code made by SuperrSonic on that other thread. Loading the game with the cheat on, I would look on the memory and find the string.

The string I found on Wave Race helped me with Mario Kart and Mario 64, but Tennis and others seem to use a different one.

Edit:
I confirm, that's the string, it works on Dolphin. The Offset is 2C960... That gives me hope for the other games seeing they can be much earlier in the file. The exact same string appears also on Mario Golf, offset D9284, A LOT later than the rest, but editing that one doesn't seem to change anything. Although, to be fair, that game looks far more bright than Tennis does.

Anyway... It's late here, I should catch some sleep. Good night to all of you.
 
Last edited by Maeson,

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
The string I found on Wave Race helped me with Mario Kart and Mario 64, but Tennis and others seem to use a different one.

It varies a lot between games, but the prologue (first few instructions) appear to be the same, and that's just enough to identify it. Still need to check other games and adjust the length of that string to something that results in only 1 search hit in all of them.

edit: if we can't get it down to 1 search hit, we can start looking at the function epilogue (last few instructions) and try to find similarities there as well, using wildcards if needed. The hex editor XVI32 allows wildcard in its searches.
 
Last edited by NoobletCheese,

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
The exact same string appears also on Mario Golf, offset D9284, A LOT later than the rest, but editing that one doesn't seem to change anything. Although, to be fair, that game looks far more bright than Tennis does.

Mario Golf is already using the full dynamic range according to Photoshop

ZZIf2i.png


i.e the title screen contains 1251 pixels at full brightness.
 
  • Like
Reactions: SaulFabre

SaulFabre

I like Yoshis and the Wii/Wii U scene.
Member
Joined
Feb 6, 2019
Messages
3,198
Trophies
2
Age
25
Location
Ecuador
Website
saulfabreg-wiivc.blogspot.com
XP
7,894
Country
Ecuador
I have played an entire game in Mario Tennis with the 00 00 15 20 15 00 00 change (and only that) on my Wii and it looks great, no banding or anything.

Mario Kart with my method also looked great.

I couldn't find the place to edit using my method for Tennis, but it doesn't matter much because the way that SuperrSonic's cheat let me find works well anyway.

I tried with Snap, without editing the BE bytes, it made no difference to me. Neither I could see the difference with the 15 20 15 method on Dolphin even when Progressive turned on.

Edit: Also tried Wave Race with the method I wrote above. What a difference!

Tomorrow I'll check SM64. And maybe Mario Golf, maybe it also works with the 15 20 15, who knows.
About Pokémon Snap 64, have you seen this message?
I've managed to remove dark filter and increase brightness of Pokémon Snap VC Wii.
I've used these procedures for do it:


Here are some screenshots:

View attachment 266121 View attachment 266122

Greetings ;)
With this question:
So it only needs to change the 16 to 20 and don't touch the other part? I didn't do it for Tennis myself when checking on real hardware...
I think numbers 16 and 20 are the max level of white that the VC emulator of N64 but i'm nt 100% sure :P

Greetings
 
Last edited by SaulFabre,

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
Here's the difference on real hardware for Paper Mario if anyone's interested.

View attachment 265954 View attachment 265955

Paper Mario is already using full dynamic range too.

ZZZ227.png


If you look at the character in the egg on the left side of the screen in your OSSC captures, there is near-white detail missing in the vfilter boosted one.

If you want more brightness for this game, increase it at your display as that will not cause clipping.
 
  • Like
Reactions: SaulFabre

SaulFabre

I like Yoshis and the Wii/Wii U scene.
Member
Joined
Feb 6, 2019
Messages
3,198
Trophies
2
Age
25
Location
Ecuador
Website
saulfabreg-wiivc.blogspot.com
XP
7,894
Country
Ecuador
Paper Mario is already using full dynamic range too.

ZZZ227.png


If you look at the character in the egg on the left side of the screen in your OSSC captures, there is near-white detail missing in the vfilter boosted one.

If you want more brightness for this game, increase it at your display as that will not cause clipping.
But I saw a small amount of darkness in the original VC release for Wii console. My friend @Zorg1996 also noticed that, so I fixed it and removed that "hidden" dark filter and made it more brighter.
Here's a comparison:

Paper Mario N64 USA DARK.PNG Paper Mario N64 USA NO DARK yay.PNG

Greetings ;)
 
  • Like
Reactions: iGom and Zorg07

SaulFabre

I like Yoshis and the Wii/Wii U scene.
Member
Joined
Feb 6, 2019
Messages
3,198
Trophies
2
Age
25
Location
Ecuador
Website
saulfabreg-wiivc.blogspot.com
XP
7,894
Country
Ecuador
Here is a magical string that should work for all N64 games.

80 04 00 04 2C 00 00 FF 40 82 00 10 80 04 00 08 2C 00 00 FF

Then walk backwards until you find the

94 21 FF E0

and replace with

4E 80 00 20
Thanks for your great info, stuff, effort and interest on removing dark filter of N64 VC games for Wii @NoobletCheese ;)

Also thanks to @MaeseJesus for still more info about it, and also to @SuperrSonic for the N64 VC emulation investigations ;)

Now me and @Zorg1996 will be working in removing dark filter to N64 Wii VC
 

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
With the vfilter boosting clipping, bear in mind it's not just brightness that gets clipped but hues and saturations also get skewed on colours when one channel starts clipping first, eg. the clouds in Pokemon Snap became a greenish colour

ZZZtoQ.png
 

Zorg07

Well-Known Member
Newcomer
Joined
Jul 14, 2019
Messages
93
Trophies
0
XP
1,013
Country
Peru
Hello there! Thank you very much for this great discovery and to be able to enjoy the Wii VC n64 games, now my question is, has someone of you been able to solve the problem of the games that are obscured in the Wii VC NES emulator?
 
  • Like
Reactions: SaulFabre

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,188
Trophies
2
XP
3,440
Country
Spain
Okay, so the non vfilter solution is the one to use then! Fantastic discovery as always, NoobletCheese! I will check the games with that string once I'm free.

It's quite curious how Mario Golf was left bright and pretty much every other game had this filter.

About NES, I haven't looked at any games. But we should consider that it might not be a filter with them. The NES, as far as I read, didn't really have exact colors, how they looked dependend on several factors. So it might be that they put those darker tones as the actual colors instead of a simple post-image effect...

I hope I'm wrong though.

Edit: ...I just thought something about these darkening filters. The VC games, at least the N64 games we've looked at, all use the "00 00 15 16 15 00 00" ones, so no filtering at all. This of course means that if you use component cables you could get a very nice, clean picture.

But it also means that if they were played on 480i, through AV or RGB cables for example, you could possibly see the flickering as the picture refreshes every frame (and being interlaced, only certain lines get refreshed each time, causing the flickering).

From what I've observed with my PS2 (most games I've tried have no filtering at all, which actually in the case of the PS2 goes against it as very few games support 480p and most games aren't even 480 in resolution but 448, making for weird pixel ratios) and stuff like Mega Man 9 or 10 when played in 480i, the flickering is most notable with white and brighter colors.

...Maybe that's the exact reason of why they added this filter: to avoid this flickering, which was the cause of many epilepsy attacks in the past, when CRTs were common. I haven't tried playing these games at 480i, just going on with the information about video filters on these games.

In any case, just an observation.

I checked the string NoobletCheese mentioned, it seems like it lands very close to the offsets I found myself, so it certainly looks like "The Ticket". Golf has the string early on in the file as Tennis.

Edit 2:

I leave here a bit of info I've been finding.
Code:
Game            Offset        Comment

Mario Kart  64    46DB8        Clears the filter. 01.app is decompressed.
Mario Tennis    2C960        Clears the filter. 01.app must be decompressed.
Super Mario 64    46210        Clears the filter. 01.app is decompressed.
Wave  Race  64    44AD4        Clears the filter. 01.app is decompressed.


1080 Snowboard    45A60        The game is not darkened. Not needed.
Bomberman Hero    27330       The game doesn't seem darkened. 
Mario Golf                    The game is not darkened. Not needed.
Mario Party 2                The game does not look darkened, must look more.
Super Smash Br.             The game is not darkened. Not Needed.

Ogre Battle 64    ---            String not present, but the game doesn't look dark.
Pokémon Snap                Unsure if it uses filter, every attempt has failed.

I completely forgot that Smash 64 was a 60 FPS game.
 
Last edited by Maeson,

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
Here is a magical string that should work for all N64 games.
80 04 00 04 2C 00 00 FF 40 82 00 10 80 04 00 08 2C 00 00 FF
Then walk backwards until you find the
94 21 FF E0
and replace with
4E 80 00 20


After checking every game listed here, the only game which doesn't have this string is Ogre Battle 64. Luckily it doesn't use the epilepsy filter so we don't need to patch it. I did find a function in its 01.app with the same epilogue and prologue as the other games, but no way of enabling the filter on so I can't test it.

Thanks to @MaeseJesus for discovering the binary strings from @SuperrSonic's cheat codes :mthr:

If you disabled the epilepsy filter by replacing 9421FFE0 and are still unsatisfied with the brightness levels, it's better to increase peak brightness on your display instead of using the vfilter as it can avoid clipping:

ZZdyk1.png
 
Last edited by NoobletCheese,
  • Like
Reactions: SaulFabre

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
After further testing, I would avoid the vfilter patching method altogether as it seems different games use different amounts of epilepsy darkening, so there is no single vfilter coefficient that would work for all of them -- it would need to be fine-tuned for each game.

eg. Mario Tennis has white pixels at RGB 216, but Wave Race is RGB 190; you'll either get clipping in Mario Tennis or not full brightness in Wave Race.
 
Last edited by NoobletCheese,

Maeson

Well-Known Member
Member
Joined
Apr 3, 2013
Messages
1,188
Trophies
2
XP
3,440
Country
Spain
Yup, changing 94 21 FF E0 is the better way to go. Good to know that only a few were darkened, though. Wonder why they decided to do it for some but not others, they seem chosen randomly.

I tried SM64 before leaving on my Wii and it looked great. I wish they put a few more N64 games on the Wii...
 
  • Like
Reactions: SaulFabre

SaulFabre

I like Yoshis and the Wii/Wii U scene.
Member
Joined
Feb 6, 2019
Messages
3,198
Trophies
2
Age
25
Location
Ecuador
Website
saulfabreg-wiivc.blogspot.com
XP
7,894
Country
Ecuador
Anybody had luck removing dark filter in the European (PAL) versions of the N64 VC releases for Wii?

Me and @Zorg1996 tried to remove the dark filter of VC Paper Mario (PAL) WAD but it didn't work... :(

Anyone did that?

Thanks in advance

PD: @Zorg1996, @MaeseJesus NES Wii VC doesn't use any dark filter. The NES console didn't have a video decoder, so it used the color pallete of the TV that was connected to the NES. Nintendo used a more darked color pallete for Wii VC games. I was wondering if that pallete can be replaced with a better color pallete for make the game more brighter and maybe a bit more colorful... :)
 
Last edited by SaulFabre,
  • Like
Reactions: Zorg07

NoobletCheese

Well-Known Member
Member
Joined
Aug 12, 2018
Messages
534
Trophies
0
Age
25
XP
1,088
Country
United States
Anybody had luck removing dark filter in the European (PAL) versions of the N64 VC releases for Wii?

The histogram for the NTSC version says it doesn't have the filter but maybe PAL version does... gimme a sec

The PAL version appears to be the same according to Dolphin

ZZmdsM.png


ZZmqDQ.png


It's still possible the output is different on Wii compared to Dolphin. I could only eyeball it though as I don't have a capture card.
 
Last edited by NoobletCheese,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • SylverReZ @ SylverReZ:
    @mthrnite, Cheetah Girls, the sequel to Action 52's Cheetah Men.
    +2
  • Psionic Roshambo @ Psionic Roshambo:
    Pokemon Black I played that one a lot
  • K3Nv2 @ K3Nv2:
    Honestly never messed with Pokémon on ds much
  • mthrnite @ mthrnite:
    I played pokemon once, was bored, never tried again
  • Psionic Roshambo @ Psionic Roshambo:
    Oh Dragon Quest IX
  • K3Nv2 @ K3Nv2:
    Spent like 5 hours on switch one never touched it again
  • Psionic Roshambo @ Psionic Roshambo:
    Sentinel of the stary skies
  • K3Nv2 @ K3Nv2:
    Ds is 20 years old this year
  • Psionic Roshambo @ Psionic Roshambo:
    So MJ no longer wants to play with it?
  • K3Nv2 @ K3Nv2:
    He put it down when the 3ds came out
  • SylverReZ @ SylverReZ:
    @K3Nv2, RIP Felix does great videos on the PS3 yellow-light-of-death.
  • Jayro @ Jayro:
    Eventhough the New 3DS XL is more powerful, I still feel like the DS Lite was a more polished system. It's a real shame that it never got an XL variant keeping the GBA slot. You'd have to go on AliExpress and buy an ML shell to give a DS phat the unofficial "DS Lite" treatment, and that's the best we'll ever get I'm afraid.
    +1
  • Jayro @ Jayro:
    The phat model had amazingly loud speakers tho.
    +1
  • SylverReZ @ SylverReZ:
    @Jayro, I don't see whats so special about the DS ML, its just a DS lite in a phat shell. At least the phat model had louder speakers, whereas the lite has a much better screen.
    +1
  • SylverReZ @ SylverReZ:
    They probably said "Hey, why not we combine the two together and make a 'new' DS to sell".
  • Veho @ Veho:
    It's a DS Lite in a slightly bigger DS Lite shell.
    +1
  • Veho @ Veho:
    It's not a Nintendo / iQue official product, it's a 3rd party custom.
    +1
  • Veho @ Veho:
    Nothing special about it other than it's more comfortable than the Lite
    for people with beefy hands.
    +1
  • Jayro @ Jayro:
    I have yaoi anime hands, very lorge but slender.
  • Jayro @ Jayro:
    I'm Slenderman.
  • Veho @ Veho:
    I have hands.
    Veho @ Veho: +1