Scaling for Hanheld system - ZFEbHVUE/Batocera-CRT-Script GitHub Wiki
Scaling for Handheld System
Example GameBoy Advance using a Shader
- Start a game from Emulation Station
- Go into the Quick Menu with [HOTKEY] + South button or Shift+F1
- Now back to the Main Menu
- Settings -> Video -> Scaling -> Aspect Ratio
- Set it from Core provided to Full
- Now back again to the Quick Menu
- Override -> Save Content Directory Override
- Exit out from the emulator and go into the newly created folder named in this example to
VBA-M
in the folder/userdata/system/configs/retroarch/config
- Edit the file
gba.cfg
and delete everything except these two lines:aspect_ratio_index = "24"
auto_shaders_enable = "true"
- Now let's make a
switchres.ini
override file:
- From the terminal type:
cp /etc/switchres.ini /userdata/system/configs/retroarch/config/VBA-M/gba.switchres.ini
- Edit the file
gba.switchres.ini
Find the line:
user_mode auto
Change it to:user_mode 320x240
- You can also use super resolutions if you want a little bit crisper image.
- 320*8 = 2560
user_mode 2560x240
Also change this:dotclock_min 0
To this:dotclock_min 25.0
- Save the file.
- Start the GBA game again from Emulation Station
- Go into the Quick Menu with [HOTKEY] + South button or Shift+F1
- Quick Menu -> Shaders -> Load Preset
- Navigate to the Pixel-art-scaling folder
- Then choose the
shader pixel_aa_xform.slangp
orbox_filter_aa_xform.slangp
(more lightweight)
- Go into Shader Parameters and change the following settings in this order:
- Force integer scaling horizontally = (1.00)
- Force integer scaling vertically = (1.00)
- Go out of the Shader Parameters and save the shader setting.
- Shaders -> Save Preset -> Save Content Directory Preset
- The file named
gba.slangp
will now be saved to the directory/userdata/system/configs/retroarch/config/VBA-M
- Next time you load up any GameBoy Advance game, the settings will be applied to all games.
Example Game Gear using a Shader
Game Gear is a special case since it needs to be stretched to 4:3.
The original hardware internally outputs 160x144 pixels, then horizontally stretched to 4:3 on the hardware while the internal aspect ratio is 10:9.
- Start a game from Emulation Station
- Go into the Quick Menu with [HOTKEY] + South button or Shift+F1
- Now back to the Main Menu
- Settings -> Video -> Scaling -> Aspect Ratio
- Set it from Core provided to Full
- Now back again to the Quick Menu
- Override -> Save Content Directory Override
- Exit out from the emulator and go into the newly created folder named in this example to
Genesis Plus GX
in the folder/userdata/system/configs/retroarch/config
- Edit the file
gamegear.cfg
and delete everything except these two lines:aspect_ratio_index = "24"
auto_shaders_enable = "true"
- Now let's make a
switchres.ini
override file:- From the terminal type:
cp /etc/switchres.ini /userdata/system/configs/retroarch/config/Genesis Plus GX/gamegear.switchres.ini
- From the terminal type:
- Edit the file
gamegear.switchres.ini
Find the line:user_mode auto
Change it to:user_mode 320x240
- You can also use super resolutions if you want a little bit crisper image.
- 320*8 = 2560
user_mode 2560x240
Also change this:dotclock_min 0
To this:dotclock_min 25.0
- Save the file.
- Start the GBA game again from Emulation Station
- Go into the Quick Menu with [HOTKEY] + South button or Shift+F1
- Quick Menu -> Shaders -> Load Preset
- Navigate to the Pixel-art-scaling folder
- Then choose the
shader pixel_aa_xform.slangp
orbox_filter_aa_xform.slangp
(more lightweight)
- Go into Shader Parameters and change the following settings in this order:
- Force aspect ratio = (0.00)
- Horizontal aspect ratio = (4.00)
- Vertical aspect ratio = (3.00)
- Force integer scaling vertically = (1.00)
- Go out of the Shader Parameters and save the shader setting.
- Shaders -> Save Preset -> Save Content Directory Preset
- The file named
gamegear.slangp
will now be saved to the directory/userdata/system/configs/retroarch/config/Genesis Plus GX
- Next time you load up any Game Gear game, the settings will be applied to all games.
Overlays in RetroArch using a Shader
Edit the file *.*.cfg
and add these lines:
aspect_ratio_index = "24"
auto_shaders_enable = "true"
input_osk_overlay_opacity = "0.700000"
input_overlay = "~/configs/retroarch/overlays/borders/overlay_name.cfg"
input_overlay_enable = "true"
input_overlay_enable_autopreferred = "true"
input_overlay_opacity = "0.700000"
input_overlay_scale_landscape = "1.000000"
input_overlay_scale_portrait = "1.000000"
input_overlay_behind_menu = "true"
Overlays are in the folder /userdata/system/Batocera-CRT-Script/extra/overlays
Copy the borders folder to /userdata/system/configs/retroarch/overlays/
Example GameBoy Advance - Without Using a Shader (Not Recommended)
- Start a game from Emulation Station
- Go into the Quick Menu with [HOTKEY] + South button or Shift+F1
- Now back to the Main Menu
- Settings -> Video -> Scaling -> Aspect Ratio
- Set it from Core provided to custom
- Now back again to the Quick Menu
- Override -> Save Content Directory Override
- Exit out from the emulator and go into the newly created folder named in this example to
VBA-M
in the folder/userdata/system/configs/retroarch/config
- Edit the file
gba.cfg
and delete everything except this line:aspect_ratio_index = "23"
Then add these 4 lines:menu_linear_filter = "true"
custom_viewport_height = "160"
custom_viewport_width = "240"
video_scale_integer = "true"
- Now let's make a
switchres.ini
override file:- From the terminal type:
cp /etc/switchres.ini /userdata/system/configs/retroarch/config/VBA-M/gba.switchres.ini
- From the terminal type:
- Edit the file
gba.switchres.ini
Find the line:user_mode auto
Change it to:user_mode 320x240
- You can also use super resolutions if you want a little bit crisper image.
- 320*8 = 2560
user_mode 2560x240
Also change this:dotclock_min 0
To this:dotclock_min 25.0
- Next time you load up any GameBoy Advance game, the settings will be applied to all games.