inochi-creator
inochi-creator copied to clipboard
Experimental: Save CPU When Losing Focus
trafficstars
TL;DR: Refactor event handling and add performance option
This update saves power without requiring changes to animation and physics animations.
- Refactored the event handling in the
incBeginLoopfunction to use a state machine for managing poll and wait modes, reducing CPU usage when the application is not focused. - Added a new performance option in the settings window called
Render Only When Window Focused. Enabling this option stops rendering when the window loses focus, further reducing CPU usage. - This feature is enabled by default
Related issue: https://github.com/nijigenerate/nijigenerate/issues/21