Skip to content

[H700] Improve display rotation handling and aspect ratio for HDMI and internal display outputs#482

Open
fedekrum wants to merge 1 commit intoknulli-cfw:knulli-mainfrom
fedekrum:theme-rotation-in-UI
Open

[H700] Improve display rotation handling and aspect ratio for HDMI and internal display outputs#482
fedekrum wants to merge 1 commit intoknulli-cfw:knulli-mainfrom
fedekrum:theme-rotation-in-UI

Conversation

@fedekrum
Copy link
Copy Markdown

This commit improves the experience of using vertical (portrait) monitors via HDMI on Allwinner H700 based devices (RG40XX, RG35XX, etc.) and adds support for independent rotation settings between internal and external displays.

Key Improvements:

  1. Aspect Ratio Correction: Automatically reports an inverted resolution (e.g., 720x1280 instead of 1280x720) when rotation is set to 90 or 270 degrees. This ensures that EmulationStation and the UI render with correct proportions without image stretching.
  2. Context-Aware Rotation: Implements persistence for rotation settings per output. The script automatically synchronizes the system's rotation setting based on whether HDMI is connected or if the internal panel is being used.
  3. Software Rotation Fallback: Forces software rotation (via EmulationStation's --screenrotate) in vertical modes. This bypasses hardware rotation limitations on the H700 chip that often cause artifacts or incorrect scaling on digital outputs.
  4. Backward Compatibility: Maintains existing logic for other boards (like RG28XX) and ensures zero impact on performance or behavior for standard horizontal orientations.

Technical Details:

  • Modified 'currentResolution' to conditionally swap dimensions based on the effective rotation value.
  • Added 'sync_rotation_per_output' to manage 'display.rotate.hdmi' and 'display.rotate.internal' configuration keys.
  • Fully compatible with the existing Knulli system settings UI.

…tputs

This commit improves the experience of using vertical (portrait) monitors via HDMI on Allwinner H700 based devices (RG40XX, RG35XX, etc.) and adds support for independent rotation settings between internal and external displays.

Key Improvements:
1. Aspect Ratio Correction: Automatically reports an inverted resolution (e.g., 720x1280 instead of 1280x720) when rotation is set to 90 or 270 degrees. This ensures that EmulationStation and the UI render with correct proportions without image stretching.
2. Context-Aware Rotation: Implements persistence for rotation settings per output. The script automatically synchronizes the system's rotation setting based on whether HDMI is connected or if the internal panel is being used.
3. Software Rotation Fallback: Forces software rotation (via EmulationStation's --screenrotate) in vertical modes. This bypasses hardware rotation limitations on the H700 chip that often cause artifacts or incorrect scaling on digital outputs.
4. Backward Compatibility: Maintains existing logic for other boards (like RG28XX) and ensures zero impact on performance or behavior for standard horizontal orientations.

Technical Details:
- Modified 'currentResolution' to conditionally swap dimensions based on the effective rotation value.
- Added 'sync_rotation_per_output' to manage 'display.rotate.hdmi' and 'display.rotate.internal' configuration keys.
- Fully compatible with the existing Knulli system settings UI.
@fedekrum fedekrum changed the title [H700] Improve display rotation handling and aspect ratio for HDMI outputs [H700] Improve display rotation handling and aspect ratio for HDMI and internal display outputs Feb 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant