11 Commits
Author SHA1 Message Date
SourMesen 819d959b84 SNES: Fixed HDMA trigger DMA syncs on every scanline even after all active HDMA channels are done for the frame (#183)
Super Bonk triggers an HDMA at the top of the screen on scanline 0 and then the HDMA channel stops. This caused the logic to call SyncStartDma & SyncEndDma on every scanline until vblank, even though no HDMA channel is active for the rest of the frame. The lost CPU time caused Super Bonk's demo to desync even earlier than hardware.
2026-06-21 01:32:54 -07:00
SourMesen e391fd8f9a Code: Add auto-formatting rules for C++ (clang-format) and enforce in CI via "clang-format" and "dotnet format" (#78)
* Code: Add auto-formatting rules for C++ projects (clang-format) and enforce code style via "clang-format" and "dotnet format"

* fix ui format warnings
2026-04-30 06:03:55 -07:00
SourMesen 1da6c1ad1e SNES: Fix clock counting logic for DMAs longer than 255 bytes (#59)
When transfer is larger than 255 bytes, i wraps back to 0, causing _dmaClockCounter to be incremented by the wrong amount. This could cause minor timing issues because the value of _dmaClockCounter is used in SyncEndDma() to determine how many cycles to stall before the CPU resumes its execution.
This appears to make the result of my old timing_test rom give a value that's closer to hardware for the last row ("WRAM DMA 1K+FR")
2026-04-24 17:58:30 -07:00
Sour 542d73029a SNES: Fixed freeze in intro/menus in Battle Grand Prix
The alignment done at the end of DMA appears to ignore master clocks spent in DRAM refresh (which is why a separate counter is needed). Unsure if this has been verified on hardware, but this is also what ares does to fix this issue.
2024-12-24 17:47:19 +09:00
Sour 831e177d87 SNES: Fixed HDMA timing issues
Passes the test_hdma, test_hdmasync, test_hdmatiming tests
2024-12-24 15:08:55 +09:00
Sour 152abf690b Rename stdafx.h to pch.h 2022-09-08 21:29:52 -04:00
Sour 991052f8bc Debugger: Lua - getDrawSurfaceSize api, added relative pos to getMouseState 2022-08-03 19:35:18 -04:00
Sour bf53d8ff8e Debugger: Register viewer - Added a few missing values 2022-07-27 18:22:49 -04:00
Sour b456170551 Save states: Serializer rework/rewrite 2022-07-20 00:40:32 -04:00
Sour c4583fc612 SNES: Added missing unused DMA registers at $43xB 2022-02-06 11:16:00 -05:00
Sour 0b228f5951 Refactoring: Added Snes prefix to files/classes 2022-01-22 11:55:17 -05:00