Initial CPP implementation

This commit is contained in:
wheremyfoodat
2025-06-30 01:33:32 +03:00
parent ce356c6e61
commit 382c0f953d
14 changed files with 658 additions and 184 deletions

View File

@@ -132,13 +132,15 @@ void Emulator::togglePause() { running ? pause() : resume(); }
void Emulator::runFrame() {
if (running) {
cpu.runFrame(); // Run 1 frame of instructions
gpu.display(); // Display graphics
cpu.runFrame(); // Run 1 frame of instructions
gpu.display(); // Display graphics
// Run cheats if any are loaded
if (cheats.haveCheats()) [[unlikely]] {
cheats.run();
}
getServiceManager().getIRUser().updateCirclePadPro();
} else if (romType != ROMType::None) {
// If the emulator is not running and a game is loaded, we still want to display the framebuffer otherwise we will get weird
// double-buffering issues