GameScope: Add support for GameScope --backend
option
#1162
+38
−13
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a combobox entry field onto the GameScope GUI to configure the
--backend
flag for GameScope. This allows users to choose a GameScope rendering backend, which can be useful to force the SDL backend on Wayland compositors in some instances for example.Regular usage of this command is shown as, for example,
--backend=sdl
, but--backend sdl
without the equals sign is also valid.gamescope --backend=sdl -- glxgears
andgamescope --backend sdl -- glxgears
are, currently, equivalent. SteamTinkerLaunch, for simplicity, currently uses the latter to forego the equals sign. If this usage ever changes we will need to revisit this.This is under the "Advanced" section and defaults to
auto
, which is the same as what GameScope currently defaults to. This selects the backend based on the environment. If the option is left atauto
, SteamTinkerLaunch does not append it to the GameScope arguments, which preserves compatibility with GameScope versions that do not have this flag (although it has been around for a bit, I am late to the party with adding support for this flag).I did some initial testing and this works. At time of writing, there are some obvious tells when a window is using SDL or Wayland, such as the mouse cursor behaving differently on SDL versus Wayland, and Borderless Window option (
-b
) does not work with the Wayland backend but does with the SDL backend. I did not test the other backends.TODO: