Tutorial  Updated

Retroarch Wiiflow Plugins: independent cores and pixel perfect scanlines

This is a little guide for widescreen wiiflow users, on how to correctly configure all Retroarch cores to reproduce the old games as they appeared on their original displays (CRT and portable consoles screens).
With Retroarch Wii, saving separate configurations it's not as straightforward as you may think, you need to "mod" the cores first.
The RA cores in this pack are already modded to save ALL settings everytime you quit, like Hexaeco does. I've not included my .cfg files because they're set for SD only and all paths may be different from yours. However with these modded cores and this guide, you can easily set everything up. You can also learn how to "mod" the cores yourself to save their own configurations.
Everyone is free to test and add updated or missing RA cores and share them here with the community.

Images are big, so you can verify scanlines accuracy zooming in

Megadrive / Game boy DMG
before:
Megadrive before.jpg Gameboy Before.jpg

after:
Megadrive after.jpg 1672617535707.jpg

real hardware:
Megadrive Real hardware.png GB DMG REAL.png

Arcade CPS3 / Game boy Advance
cps.jpg GBA.jpg

Arcade Mame
Arcade Aliens.jpg Arcade 1943.jpg

Arcade Neo Geo / Wonderswan Color
Neo Geo Metal Slug.jpgWonderswan Color.jpg


-This guide assumes that both your Wii console and TV are set to 16:9 aspect ratio
-I'm not using the newest RA cores from the latest Wiiflow Plugins Pack, because I can't get the scanlines to work with them. I've currently re-edited the older RA cores from the Plugins Pack Rev 6 (RA 1.7.6 through 1.8.8) to TOTALLY save separate configurations. They work really good even if they're less recent versions.
-Menus are rearranged differently between the various RA versions, the important settings are generally found in submenus called: Video, Options, Overlays.
-In a few cases, it's not possible to achieve pixel perfect resolution and aspect ratio on the Wii, because some games require a bigger vertical resolution than the wii or different pixel's aspect ratio than your TV.
-I removed non-working cores from Retroarch-Wii (e.g. Fceumm, snes9x_next), but I've included their RA-Hexaeco counterparts, plus some other Hexaeco cores as an alternative. This pack is not complete by any means, but the "main" emulators should be there.
-This guide partially works with RA Hexaeco. I couldn't edit the cores to save separate core-options files, only regular settings. But it can be possible, I guess.

INSTALLATION AND CONFIGURATION:

1 - Backup and then delete all your existing Retroarch files within wiiflow/plugins and on root.
Do it in order to prevent conflicts with configurations and to be able to restore your previous RA setup anytime.
Seriously, do a backup! I take no responsability if you don't.
DON'T delete the .ini files.
Make sure to make a backup of these folders, then delete all .dol and .cfg files contained:
retroarch
retr52rch
wiiflow/plugins/Retroarch-Wii
wiiflow/plugins/Arcade/MAME_2003_plus/mame_dols
wiiflow/plugins/Arcade/MAME_2003_plus/mame_alt_dols
wiiflow/plugins/Arcade/FBA_VM/dols
wiiflow/plugins/RA-HEXAECO

2 - Download my Cores Pack. Extract it and copy the content of each folder to the following paths:
wiiflow/plugins/Retroarch-Wii
wiiflow/plugins/Arcade/MAME_2003_plus
wiiflow/plugins/Arcade/FBA_VM
wiiflow/plugins/RA-HEXAECO
private/VTREX

* Don't forget to put the Bios files in the system directory. They're not included in this pack.
**The 'private' folder is included only for Vectrex overlays but it can also contain your SD wii channels.
DON'T delete it, just add the VTREX folder and its content to your private folder.

3 - Some .dol filenames have been changed.
Open "RA_cores_hex-editing.txt" to see all file names.
Update your plugins .ini files with the new .dol names.

4 - Open "RA_settings.txt" and follow directions to change the required settings for each core.

-END.

ENJOY YOUR GAMES WITH THIS NEW SETUP!
Post automatically merged:

Read the following tutorial to learn the process, if you want to add some missing cores or update them with new versions.

TUTORIAL: Retroarch Wii - per core configurations and pixel perfect scanlines

Preparing and hex editing the .dol files
Normally, all Retroarch cores save their settings in 2 global files: retroarch.cfg and retroarch-core-options.cfg.
This is where Retroarch fails, if you ask me. Some settings, like screen resolutions, can't be global because so many systems worked at different resolutions.
Furthermore, some cores like Genplus_GX or Gambatte, are each one emulating "groups" of machines, all requiring different video setups.
For example, all Sega consoles emulated by Genplus_GX use different resolutions, while Gambatte can use a different overlay grid and colorization for the DMG Game boy and the GBC. So, if you set Genplus_GX for the Game Gear, the same settings would then be used for the Megadrive too, forcing you to re-adjust settings each time. To prevent this madness, you first need to make duplicates of these cores and hex edit them so that they are treated as independent emulators.
- Make multiple copies of these cores, and rename them in a way that helps differentiate the platforms:


e.g.
gambatte_libretro_wii.dol
copied and renamed as:
gambatte_libretro_wii_DMG.dol
gambatte_libretro_wii_GBC.dol


All .dol files must be hex edited to save separate configurations, in order to prevent conflicts (thanks @Wiimpathy for his tutorial).
To make all cores completely independent, however, you must specify a new name for BOTH 'retroarch.cfg' AND 'retroarch-core-options.cfg':

- Open your .dol file with an hex editor
- In the search field, type .cfg and search for text
- Find and replace the text 'retroarch.cfg' with a name with the same lenght, which helps to identify it:

e.g.
retroarch.cfg --> original name
gamb_dmg_.cfg --> same lenght, name identifies Gambatte and DMG Game boy


There are multiple 'retroarch.cfg' entries, but the only one to change is the one next to 'system'

- Do the same with 'retroarch-core-options.cfg'.
In the file 'RA_cores_hex-editing.txt' you will see a complete list of the names I've used for .cfg files, as a reference.

e.g.
retroarch-core-options.cfg --> original name
gamb_dmg_-core-options.cfg --> same lenght, only the 'retroarch' part has been changed


- Save your file and copy this modified .dol to your sd card.
- Delete all residual .cfg files for that core in the retroarch root folder and retroarch/config
- Launch this dol. You should see a 'welcome' message on the first boot


1 - Disable all default filters
- Go to 'Settings' then 'Video'
- Set 'Bilinear filtering' to OFF
- Set 'Soft Filter' to OFF
- Set 'Deflicker' to OFF
- Go to 'Video' > 'Output' and click on 'Screen Resolution' to apply Deflicker OFF

Note: You can't really disable 'Bilinear Filtering' because of a little bug. Disabling Bilinear Filtering will just remove blur from menus, no changes in the game graphics. Sometimes it will occasionally disappear in Genplus_GX games, only to reappear later on when the game switches resolutions. Leave 'Bilinear Filtering' enabled only with Genplus_GX.


2 - Set up Screen Resolution (vertical Height)
The best result can be obtained if the game can be displayed at a pixel perfect scale (2x or 3x, depending on the case).
With some consoles (mostly Sega), before you work on the video resolution, you have to first set 'Borders' to 'FULL' in the 'Options' menu, because it will affect width and height in pixels.
- Launch your game and select 'Settings' > 'Video' > 'Scaling'
- Set 'Integer Scale' to ON.
- Select 'Custom Aspect Ratio height' and set it to 2x or 3x, depending on the original game resolution.
Take note of the chosen Height value (vertical resolution).
At this point, you will face 3 possible scenarios:

a) Vertical 2x resolution is 448px (e.g. Megadrive, SNES, many arcade games...).
This is optimal for the Wii, as it vertically takes up the entire screen and it's a pixel perfect scale.
- Change the 'Screen Resolution' from 'Default' to 640x448.

b) Vertical 2x resolution is bigger than 448px (e.g. NES, PC-engine, some arcade games, ...).
If the difference is minimal (e.g. 480 instead of 448 pixels) and you can see all the important stuff like health bars, inventory, etc.:
- Keep the default Screen Resolution (640x480)
If the difference is bigger, or you can't see important stuff like health bars, inventory, etc.:
- Reduce Screen Resolution to 640x448, renouncing to pixel perfect scaling

c) Portable consoles. A 3x scale will generally fit the screen, but if you find it too big and blocky, use a 2x custom scale.
- Use the default Screen Resolution (640x480)
- Choose a Custom Aspect Ratio of 2x or 3x
- Set 'Integer Scale' to OFF and adjust the X and Y position to center the picture


3 - Width adjustment
a) If your integer custom height is matching the vertical screen resolution (e.g. they're both 480px):
- Set 'Aspect Ratio' to 'Core Provided' or '4:3' or, '1:1 PAR', depending on the case. It will just shrink/stretch the picture horiontally.
Most emulators will look right in 4:3 mode but sometimes width proportions will not look right.
Try to find some circular or square shape in the game graphics, then try to switch between the above mentioned aspect ratios until they look correctly sized.
If it's still looking too thin, set 'Screen VI Width' to a greater value than 640, then click on 'Video' > 'Output' > 'Screen Resolution' to apply VI Width.

b) If your custom height is smaller than your vertical screen resolution (e.g. portable consoles at 2X scale), you have no other option than using:
- 'Aspect Ratio' = 'Custom'
On portable consoles the aspect ratio will look a little horizontally stretched, because the actual pixels aspect ratio was different. However, the difference is never too big and it's the only way to perfectly apply grid scanlines. In my opinion it's still better than a filtered image.
You can only try to adjust width by changing the appropriate settings on your TV, if available.


4 - Apply the correct scanlines overlay
- Go to 'Quick Menu' and select 'Onscreen Overlay' = 'ON'.
- Choose 'Overlay Preset' and select scanlines with the same resolution and scale of the game.
(open RA_settings.txt to see the correct overlays to use).
- Set 'Overlay Scale' to 1.00 and 'Overlay Opacity' to your liking (don't overdo it, or the screen will become too dark).


5 - Saving
Cores configuration files will be saved in the Retroarch folder on root
- When you quit the app, all settings are automatically saved in separate per-core .cfg files, similarly to RA Hexaeco.
- Make sure that 'Save Configuration on Exit' and 'Use Global Core Options File' are both set to 'ON'. They're generally found in 'Settings'>'Configuration' submenu.

Arcade games are a different story, each game is often a separate machine with its own resolution.
- Always use 'Save Game overrides' with Arcade games
See 'RA_cores_hex-editing.txt' for a full list of all the .cfg files that will be generated.


6 - "Locking" configuration
Once you're satisfied with the configuration, I suggest you to choose:
'Save Configuration on Exit' = 'OFF'.
This way you will prevent Retroarch to pointlessly save everytime.
You will also prevent to accidentally mess up with the configuration.
 

Attachments

  • RA_ settings.txt
    19.5 KB · Views: 128
  • RA_cores_hex-editing.txt
    5.4 KB · Views: 162
Last edited by Tetsuo Shima,

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
These cores will save their own cfg files, so they can cohexist with other RA installation.
However I've never tried having two retroarch folders, one SD and one on USB at the same time, if this is what you want to do. I also have a regular Wii, not familiar with WiiU RA.
I don't think there will be any issues, but I suggest you to do a full backup of your RA folders before trying
 

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
@Tetsuo Shima. Problem afaik, ratroarch-wii (Heaxeco ?) save retroarch.cfg every changes.
So I have to make settings, and overwrite with RA WiiU retroarch.cfg
Don't know if my WiiU RA config.cfg will alter tetroarch-wii and heaxeco settings ?

@Tetsuo Shima Ok by reading more attentively the OP, I understand more the setup. Maybe there is one core that there is not his one moddified retroarch.cfg
 
Last edited by jul16ares,

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
@Tetsuo Shima. Problem afaik, ratroarch-wii (Heaxeco ?) save retroarch.cfg every changes.
So I have to make settings, and overwrite with RA WiiU retroarch.cfg
Don't know if my WiiU RA config.cfg will alter tetroarch-wii and heaxeco settings ?

@Tetsuo Shima Ok by reading more attentively the OP, I understand more the setup. Maybe there is one core that there is not his one moddified retroarch.cfg
My cores are hex-edited to not save anymore on the global retroarch.cfg file. It won't be used at all.
If you open the file 'RA_cores_hex-editing.txt' you will see where each RA core is saving his settings.
Hexaec0 won't conflict with standard RA too. It saves settings on an entirely different folder, so don't worry

Edit:
Be sure to configure the cores like this:
go to Settings -> Configuration
and choose:
Save Configuration on Exit=ON
Load Content-Specific Core Options Automatically=OFF
Load Override Files Automatically=ON
Load Remap Files Automaticallu=ON
Use Global Core Options File=OFF
 
Last edited by Tetsuo Shima,

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
Save Configuration on Exit=ON

Use Global Core Options File=OFF
I have only these two on Settings>configuration

mednafen-pce-fast, genesis_plus_gx don't save settings, but core saves config files under sd:/retroarch/
exept mednafen-pce-fast save just pce_fast_.cfg and not pce_fast_core_options.cfg

I have problem to plugin detection, can't set plugin for gambatte, and neo-geo games for the moment
 
Last edited by jul16ares,
  • Like
Reactions: Tetsuo Shima

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
I have only these two on Settings>configuration
Yes, it's normal. In my example there are the settings I used for gambatte. Other cores may come from different RA versions so it's possible there are some slight differences. In your case however the settings you mentioned are correctly configured.

mednafen-pce-fast, genesis_plus_gx don't save settings, but core saves config files under sd:/retroarch/
exept mednafen-pce-fast save just pce_fast_.cfg and not pce_fast_core_options.cfg
You are right. I don't know why, but even if I edited the .dol file to save in sd:/retroarch/pce_fast_core_options.cfg it's saving in sd:/retroarch/config/Beetle PCE Fast/Beetle PCE Fast.opt instead. It must be hardcoded.
However, there are no issues about it. The core-options in this case can be the unified for PCE and PCE CD (in fact it didn't require to be duplicated, like Gambatte DMG and GBC, which require different palettes, or genesis_plus_gx for MD, GG etc. which require different screen resolutions). It's the same console, just with a different media, just like genesis and sega cd.

I have problem to plugin detection, can't set plugin for gambatte, and neo-geo games for the moment
For gambatte did you update your plugin .ini files with the new dol names?
 

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
Mame 2003+ was too heavy for the Wii, so it was splitted in multiple cores, each one focusing on a few selected drivers.
Used together these cores grant an incredible compatibility, you just need to use the correct romset. Then you have to put your roms in separate folders, to be used with the proper core.
It is a must that you take some time looking at Mame 2003+ compatibility list , there's a full (or so) list of supported games and which core to use. If you use mame 2003+ from the Plugins Pack, you just need to put the roms in the proper folders, following the compatiility list, anf you're ready to go.
 
  • Like
Reactions: cheloruiz79

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
These cores will save their own cfg files, so they can cohexist with other RA installation.
However I've never tried having two retroarch folders, one SD and one on USB at the same time, if this is what you want to do. I also have a regular Wii, not familiar with WiiU RA.
Yes it works, WiiU RA (1.16) AND WFL both on the same retroarch folder, with your independant cores setup files !
Owever Gambatte for GBC still crash, and throw me on Wii menu
 

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
I was wrong, something somehow alter retroarch.cfg, and I get back red screen on RA WiiU snes9x. I launched before gamebatte on WFL
I'll try to stop save cores settings on exit, but that don't make much sens
 
Last edited by jul16ares,

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
Hmm it's strange. I don't know if gambatte is really responsible . I've changed all 'retroarch.cfg' instances in the .dol file and in fact it doesn't alter the file after I use gambatte (which I use quite often actually)
The screen is all red, or you can still see the game?
In the first case maybe you accidentally changed the video driver? or it's a palette issue?
 

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
Realy havn't done anything special, just launched WFL with gamebatte.
Yes just plain red screen, still heard sound
 

Tetsuo Shima

Well-Known Member
OP
Member
Joined
Oct 29, 2008
Messages
1,874
Trophies
2
Age
45
XP
4,889
Country
Italy
I cannot reproduce the issue, sorry.
After I use gambatte nothing is written in retroarch.cfg.
For the snes I use Hexaeco's snes9x_next from this pack, because all the RA versions I've tried are either buggy or don't work with scanlines.
Some things to try:
- Try another game rom
- Check if threaded video was accidentally enabled
- Try to disabile cheats of you have this option
 

jul16ares

Well-Known Member
Member
Joined
Dec 25, 2018
Messages
175
Trophies
0
XP
845
Country
France
I cannot reproduce the issue, sorry.
After I use gambatte nothing is written in retroarch.cfg.
For the snes I use Hexaeco's snes9x_next from this pack, because all the RA versions I've tried are either buggy or don't work with scanlines.
Some things to try:
- Try another game rom
- Check if threaded video was accidentally enabled
- Try to disabile cheats of you have this option
Ok I think it's shaders with RA WiiU, seems broken with v1.16
 
  • Like
Reactions: Tetsuo Shima

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    K3Nv2 @ K3Nv2: Lol rappers still promoting crypto