An original GameBoy emulator in C++ using SDL graphics
This emulator is reasonably accurate; it passes Blargg's timing and CPU tests. It can also run most games I've tested without issues. I have not implemented hardware bugs such as the HALT behaviour or the OAM bug since I have not yet found a game that relies on these behaviours.
Consider Sameboy for accurate hardware emulation.
- g++ 7.5+
- SDL2 (for graphics and input)
Build using make
. Optionally build for development using: make debug
.
I have been able to build and run this project in WSL using VcXsrv as an X server for graphics. This solution will still perform well; on my machine this can achieve 40x real time emulation.
I have not yet implemented audio emulation, however this project does attempt to emulate the behaviour of the audio registers in order to avoid unexpected behaviour in games that rely on them.
The default control mappings are:
Function | Keyboard mapping |
---|---|
A | W |
B | Q |
SELECT | Enter |
START | Space |
D-PAD | Arrow Keys |
Toggle Framecap | S |
The following links point to documentation that I found useful.