feat: Enhance Emulator and Rendering Performance with New Features

- Implemented a Cleanup method in the Emulator class to manage resources effectively during shutdown.
- Added auto-pause functionality to the emulator when the window loses focus, optimizing CPU and battery usage.
- Updated the DoRender method in the Controller class to include frame timing management and a gentle frame rate cap.
- Enhanced texture processing in the Arena class to batch process up to 8 texture commands per frame, improving rendering efficiency.
This commit is contained in:
scawful
2025-10-07 18:16:36 -04:00
parent 0c3c8ebca7
commit defc99b571
7 changed files with 1117 additions and 5 deletions

View File

@@ -32,6 +32,10 @@
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
[self setupMenus];
// Disable automatic UI state persistence to prevent crashes
// macOS NSPersistentUIManager can crash if state gets corrupted
[[NSUserDefaults standardUserDefaults] setBool:NO forKey:@"NSQuitAlwaysKeepsWindows"];
}
- (void)setupMenus {