Repository navigation
retrocast is a static recompiler for retro consoles and arcade boards: it translates a game's machine code into C and builds it into a native program, with a small runtime per system and an SDL3 window, sound and gamepads. Recompiled games are checked cycle by cycle against a built-in reference interpreter.
Systems: NES and Famicom Disk System (6502), Game Boy and Game Boy Color (SM83), Genesis / Mega Drive (68000 and Z80), Atari 2600 (6507), Master System / Mark III and Game Gear (Z80), Capcom Play System I (68000 and Z80), Capcom Play System II (68000 and Z80), Neo Geo MVS and AES (68000 and Z80), PC Engine / TurboGrafx-16 HuCards (HuC6280), and Atari 7800 and 5200 (6502).
In the window, Esc (or Select+Start on a gamepad) pauses the game and opens a menu: save and load state, reset, quit, and the system's and the window's settings in tabs, saved to the .ini at once.
No games are included: bring your own legally dumped ROMs and disk images (disk games also need the FDS BIOS, Atari 5200 games the console's BIOS; Game Boy games need no BIOS). CPS-1 games are MAME / FBNeo ZIPs matched by chip CRC. CPS-2 uses named MAME set ZIPs and any required parent ZIPs. QSound games on both boards need qsound.zip.
Downloads
Windows (x64, arm64), Linux (x64, arm64; glibc 2.35+), macOS (Apple Silicon). Each archive has:
retrocastruns the systems with SDL support. It identifies the system from the file, with--systemavailable for manual selection.- one headless program (
*_headless: the game without a window, for scripts and checks) and one recompiler (*recomp: the game to C) per system; each prints its options when run without arguments:
| System | Headless | Recompiler |
|---|---|---|
| NES, Famicom Disk System | nes_headless |
nesrecomp |
| Game Boy, Game Boy Color | gb_headless |
gbrecomp |
| Genesis / Mega Drive | genesis_headless |
genesisrecomp |
| Atari 2600 | atari2600_headless |
atari2600recomp |
| Master System, Game Gear | sms_headless |
smsrecomp |
| CPS-1 | cps1_headless |
cps1recomp |
| CPS-2 | cps2_headless |
cps2recomp |
| Neo Geo MVS and AES | neogeo_headless |
neogeorecomp |
| PC Engine / TurboGrafx-16 | pce_headless |
pcerecomp |
| Atari 7800 | atari7800_headless |
atari7800recomp |
| Atari 5200 | atari5200_headless |
atari5200recomp |
kit/: recompiles your own ROMs into native programs with only CMake and a C compiler installed (SDL3 comes prebuilt)
README.txt in the archive explains how to play and how to recompile. macOS builds are unsigned: run xattr -dr com.apple.quarantine retrocast-* once after unpacking.
Do not share recompiled programs: they contain the game.
Supported games and known limitations: NES, Game Boy, Genesis, Atari 2600, Master System and Game Gear, CPS-1, CPS-2, Neo Geo, PC Engine, Atari 7800, Atari 5200.
What's Changed
- Neo Geo window: check the save paths; CI compiles the window code with gcc by @Viper-Bit in #124
- Neo Geo: cpu_speed, a faster 68000 against the slowdown by @Viper-Bit in #125
- cpu_speed for the Genesis, CPS-1 and CPS-2 by @Viper-Bit in #126
- Window menu P1: Esc pauses the game and opens a menu by @Viper-Bit in #129
- Window menu P2: tabs for the system's and the window's settings by @Viper-Bit in #130
- Window menu P3: the gamepad opens and works the menu by @Viper-Bit in #131
- Window menu P4: the build contract by @Viper-Bit in #132
- Window menu P5: the release docs by @Viper-Bit in #133
- PC Engine P1: the HuC6280 by @Viper-Bit in #134
- PC Engine P2: the machine, VDC and VCE by @Viper-Bit in #135
- PC Engine P3: the PSG by @Viper-Bit in #136
- PC Engine: the whole-library sweep against MAME by @Viper-Bit in #137
- Atari 7800 P2: POKEY cartridge audio by @AMMIROSOH in #127
- Atari 5200 P3: BIOS, ANTIC and GTIA by @AMMIROSOH in #138
- fix(cmake): quote rom paths in custom commands with verbatim by @towhidzei in #140
- PC Engine P4: the recompiler by @Viper-Bit in #142
- Atari 5200 and 7800 P4: trace-driven 6502 recompiler by @AMMIROSOH in #141
- PC Engine P5: the window, four pads, saves and the detector by @Viper-Bit in #143
- PC Engine P6: save states by @Viper-Bit in #144
- PC Engine P7: the build contract by @Viper-Bit in #145
- PC Engine P8: release by @Viper-Bit in #146
- Site: uploading a list no longer starts the site build by @Viper-Bit in #147
- Roadmap: the PC Engine's P9 split into SuperGrafx and CD-ROM² by @Viper-Bit in #148
- Atari 7800: its own palette for RGB output by @Viper-Bit in #149
- Atari 7800 and 5200 P5: the window by @Viper-Bit in #150
- Atari 7800 and 5200: the other cartridge boards by @Viper-Bit in #151
- Atari 7800 and 5200 P6: save states by @Viper-Bit in #152
- Atari 7800 and 5200 P7: the build contract by @Viper-Bit in #153
- Atari 7800 and 5200 P8: release by @Viper-Bit in #154
- Site: keep only the pictures shown; Atari 7800 and 5200 roadmaps by @Viper-Bit in #155
- Atari 7800 and 5200: a lazy clock by @Viper-Bit in #156
- Atari 2600: the shared 6502 recompiler by @Viper-Bit in #157
- CPS-2: 2.8 times as fast (drawing and Q-Sound) by @Viper-Bit in #158
- Neo Geo: 1.3 times as fast (sprites and YM2610) by @Viper-Bit in #159
- CPS-1: 3.9 times as fast (drawing and picture) by @Viper-Bit in #160
- Genesis: 1.6 times as fast (drawing) by @Viper-Bit in #161
- PC Engine: 2.1 times as fast (PSG and background) by @Viper-Bit in #162
Full Changelog: v0.10.0...v0.11.0