-
Notifications
You must be signed in to change notification settings - Fork 24
RetroArch
Table of Contents generated with DocToc
- About
- Warning
- RetroArch Web Player
- Installation
- General
- Using the online updater
- Source build information
- Demonstration video
- General
- Disc Images
- Input
- Cores
Retroarch is the reference frontend for the libretro API. Popular examples of implementations for this API includes videogame system emulators and game engines, but also more generalized 3D programs. These programs are instantiated as dynamic libraries. We refer to these as "libretro cores".
"libretro" is an API that exposes generic audio/video/input callbacks. A frontend for libretro (such as RetroArch) handles video output, audio output, input and application lifecycle. A libretro core written in portable C or C++ can run seamlessly on many platforms with very little/no porting effort.
While RetroArch is the reference frontend for libretro, several other projects have used the libretro interface to include support for emulators and/or game engines. libretro is completely open and free for anyone to use.
Note:
You can also find great information about Retroarch, the emulators themselves, and more, at the RetroPie wiki.
Please ensure you have the Debian and Libregeek repositories added. You can reference the main README.md file for complete details.
A beta recently surfaced of the RetroArch "Web Player." You can check out some footage of it in action here. Try it out over at https://buildbot.libretro.com/web/.
If you do not want to install all cores, you can skip the routine above and install them separately. Instead of [CORENAME], you can use an asterisk (i.e. libretro-*
) to install all cores. The list of cores can be referenced from this list
sudo apt-get install retroarch retroarch-joypad-autoconfig
sudo apt-get install libretro-[CORENAME]
Building Retroarch and Libretro cores from source is called from the main desktop-software
script.
./desktop-software.sh install retroarch-src
However, if you wish to built a specific core, you can specify the core name as so:
./desktop-software.sh install retroarch-src mame
For a list of cores, please reference this libretro-super file.
If you installing via the retroarch-src
or install type, currently you must still perform the following:
- Add "Retroarch-Src" as a "non-Steam" game using the "+" icon on the Libary section of SteamOS
- Transfer any ROMs you had on your system, into appropriate folder structures under
/home/desktop/ROMs
. - Due to auto-detection now being used for all gamepads, when you start RetroArch, it is suggested to set the following in Settings > Input Hokey Binds:
- Save State
- Load State
- Quit Retroarch
- Menu Toggle
Please note:
The /home/steam/ROMs
directory is a symlink of the source directory, /home/desktop/ROMs
If you did not use the desktop-software.sh
installation method, this symlink will not exist.
RetroArch contains an online updater that currently pulls in the latest assets, cores, and shaders. If you wish to have these available as soon as they are built by the Libretro buildbot, you must change the applicable directory within the RetroArch settings menu to a directory that is writable by your user.
The suggested directory is: ~/.config/retroarch/cores/
Here is an example for PSX/PS1 BIOS files. Mednafen is very picky about which BIOS to use. The ones that you might need are:
- scph5500.bin
- scph5501.bin
- scph5502.bin
Copy this file to wherever you assigned the "system" directory. If unassigned, this would fall under the same directory as the game ROM. Be careful of case, as some systems expect lower or uppercase BIOS file names.
Below you can find related information pertaining to building Retroarch/Libretro from source. This will only include items outside the automatic build script invoked by desktop-software.sh
.
This video comes courtesy of Ryochan7, Thanks! (Click to Play)
If you used the desktop-software method, the "system" directory of RetroArch is pre-configured to /home/<user>/ROMs
, so you'll want to also dump your BIOS files in this location as well.
Mednafen requires you to load games through CUE sheets. Ensure that the CUE sheet is properly set up in order for the game to run. See the Cue sheet (.cue) for more.
#Input (General)
Below is all available known information for gamepad input and control. Please submit suggestions as an issues ticket.
RetroArch uses a weighted system to pull which controller configuration it should use(see: here). Priority is given to the file that matches the name:vid:pid triplet, and then falls back to file that matches just vid:pid, and finally to file that matches just the name. You can reference the list of configurations at the retroarch-joypad-autoconfig GitHub repository.
##Input (Xbox 360 Controllers) The Xbox controllers are mapped exactly has Retroarch has requested each button to be. See the below diagram.
##Input (Sony PS3 Controllers)
The Sony Dualshock 3 controller is setup in the same fashion as the above Xbox 360 controller. The main things to keep in mind are
- X is "A"
- Circle is "B"
- Square is "X"
- Triange is "Y"
Cores are available via two methods:
- Debian packages (e.g.
libretro-desmume
) - The online updater within Retroarch
You have one choice of how you wish to proceed here. The Debian packages install to a standard, but protected, area of /usr/lib/libretro/
. This is not typically writable by a user. If you wish to have cores available as soon as they are built by the Libretro buildbot, you must change your "Core Directory" within the RetroArch settings menu to a directory that is writable by your user.
#Troubleshooting
The problem, that "B" crashes RetroArch at random, can be worked-around by changing the hotkey for closing RetroArch to another key than "ESC". The issue is that it's starting in keyboard mode, where B is mapped to ESC. For some reason, you can still traverse the menu with this. This could be due to the Steam Controller sending "B" vs. RetroArch
Alternative:
You could also install SC-Controller and ran sc-xbox.py start. This causes it to emulate an XBOX 360 controller and it seems to work fine. As for why it allows you to traverse the menu I cannot say, in my case pressing B at any time caused RetroArch to close. You can use evtest to identify which mode it is in, so I recommend doing that.
See: retroarch-joypad-autoconfig/issues/225
Log files are not typically enabled automatically. Achieving logging (if needed) can be achieved in a few short steps. For a description of log levels, please see the default upstream config file
First, modify this line under /home/steam/.config/retroarch/retroarch.cfg
to include your desired log level (DEBUG = 0, INFO = 1, WARN = 2, ERROR = 3):
libretro_log_level = "0"
Second, copy the debug launcher and desktop files:
sudo cp SteamOS-Tools/launchers/retroarch-debug /usr/bin
sudo cp SteamOS-Tools/cfgs/desktop-files/retroarch-debug.desktop /usr/share/applications
Next, add this shortcut via Steam (Settings > Add Library Shortcut). The log will be located in the home directory of the steam user:
desktop@steamos:~$ ls /home/steam/retroarch/
log.txt saves
You can attach these logs to pastebin service (like Slexy or GitHub Gist). If you wish to upload to a paste services via the command line, see Attaching and Submitting log files.
Some shaders, such as eagle, are of a .cg
not .cgp
file extension/type. Loading shader presets only works with a .cgp
file.
To load cg files, load a cgp shader (i.e. one that you can see), increment the passes by 1 and then go to where it says N/A and navigate to the .cg
file. Alternatively, you can change the first pass, but I suggest adding another pass to add this cg file.
##My game won't launch from detect core! (source build only) As it was today, 20150607, there are times when building from and active Git source can be a disadvantageous. For all the benefits it brings, there will be times when things break. In this example a bad commit broke core detection mechanisms for content loaded. However, you can still load the core, then the content just fine.