Add manual rotation config option for portrait panels where KMS reports native resolution.#4877
Add manual rotation config option for portrait panels where KMS reports native resolution.#4877sam1am wants to merge 4 commits intoLizardByte:masterfrom
Conversation
ReenigneArcher
left a comment
There was a problem hiding this comment.
Can we auto detect the rotation? I ask because if the user has multiple monitors and switches between which ones are streamed, this solution is likely to be painful.
|
Oh hey this shader was one of the things I wanted to investigate for #4788 since the protocol can send a wonky framebuffer with transform as metadata. So yeah this setting could use some more options, i.e. even 0deg should be explicitly set, not the default, and the default should be auto, i.e. let the platform decide. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Adds a manual_rotation config option (0, 90, 180, 270 degrees) for portrait panels used in landscape orientation (e.g. Steam Deck) where KMS reports raw panel resolution instead of logical orientation.
…ically - Web UShader duplication documented - Created tests/unit/test_config.cpp with parameterized tests covering: - All valid rotation values (0, 90, 180, 270) - Invalid values that should normalize to 0 (45, 360, -90, 1, non-numeric abc) - Default value verification
- Add const to structured binding to avoid unnecessary copy - Add NOLINT comments for unordered_map usage (test compatibility)
|
|
I think this would be a great fix for the GPD Pocket 4, which is one of the devices with this problem. I'm not sure how auto detection would work, since I think there's multiple ways to handle this kind of display on Linux. For example, on my installation I rotate the display in the Sway configuration, the same way you'd rotate it for a regular monitor used vertically. And, actually, the GPD Pocket also supports folding the display into "tablet mode", in which case the original orientation makes sense. In general, you simply can't tell how the user is looking at the display. In any case, the option in this PR is clearly called "manual" rotation in both the UI and code. I might test this PR if I can manage to build Sunshine on Guix (I'm currently using the Flatpak). |




Description
Adds a manual_rotation config option (0, 90, 180, 270 degrees) for portrait panels used in landscape orientation (e.g. Steam Deck, GPD, etc.) where KMS reports raw panel resolution instead of logical orientation.
Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage