code icon indicating copy to clipboard operation
code copied to clipboard

Support Game Mode on macOS

Open CRH258 opened this issue 10 months ago • 1 comments

Please confirm the following.

  • [x] I checked the existing issues for duplicate feature requests
  • [x] I have checked that this feature request is not on our roadmap

What parts of Modrinth is your feature request related too?

App

Is your suggested feature related to a problem? Please describe.

No response

Describe the solution you'd like

macOS Sonoma has a game mode, and the game subprocess launched by mojang official launcher can be correctly triggered in fullscreen mode. Instead, Modrinth App, which also has the

<key>LSApplicationCategoryType</key>
	<string>public.app-category.games</string>

attribute in info.plist, still cannot trigger the game mode for the Java game subprocess after launched.

Possible reasons:

  1. the mojang launcher typically remains running as the parent process during gameplay, which may be critical for macOS recognition
  2. For Modrinth App: Event loop leads to Metal rendering. /// For Official Launcher: Event loop ties to CGLFlushDrawable and glSwap_Exec, indicating traditional fullscreen rendering. So while both enter fullscreen, the official launcher’s OpenGL-based refresh mechanism may better match Game Mode’s trigger criteria.
  3. The persistent launcher parent process may provide context that macOS associates with gaming.

Describe alternatives you've considered

  1. Keep the Launcher Running (Failed)
  2. Force OpenGL Rendering(I don't know how to do it and it may not work)
  3. Adjust Info.plist Context
  4. Enable force full screen in the options in Modrinth App

Additional context

If the game mode can be supported, low-end Macs can also run more smoothly🙏

CRH258 avatar Mar 01 '25 19:03 CRH258

Duplicate of #968

piprett avatar Mar 03 '25 15:03 piprett