diff options
author | Nebuleon Fumika | 2012-12-21 03:50:10 -0500 |
---|---|---|
committer | Nebuleon Fumika | 2012-12-21 03:50:10 -0500 |
commit | a0d0c5e7a5bdc396b4c370a750273b6e3b963bb0 (patch) | |
tree | 6bc433422db602b974a01dffbfc5ce5d84afc578 /source/nds/gui.c | |
parent | 3972512b2a5c25236ea3ba586621dba6e5b56361 (diff) | |
download | snesemu-a0d0c5e7a5bdc396b4c370a750273b6e3b963bb0.tar.gz snesemu-a0d0c5e7a5bdc396b4c370a750273b6e3b963bb0.tar.bz2 snesemu-a0d0c5e7a5bdc396b4c370a750273b6e3b963bb0.zip |
Eliminate the latency of button press recognition, which was bad enough to lose keys entirely sometimes, and could otherwise delay a button press or release by 200 ms.
This was the entire reason I created the fork, and I finally did it! It syncs the controls every scanline of a frame, which costs about 60,000 MIPS instructions per frame to deal with. Luckily, the processor runs at 396 MHz, which means the cost of checking the controls is 1% of the CPU's power.
Diffstat (limited to 'source/nds/gui.c')
-rw-r--r-- | source/nds/gui.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/nds/gui.c b/source/nds/gui.c index bf85b67..4a04efc 100644 --- a/source/nds/gui.c +++ b/source/nds/gui.c @@ -1714,6 +1714,7 @@ u32 menu(u16 *screen) void menu_exit() { + ds2_setCPUclocklevel(13); // Crank it up, leave quickly if(gamepak_name[0] != 0) { game_config.clock_speed_number = clock_speed_number; |